s4: free popt context in dnsserver
[samba.git] / source4 / dns_server / dlz_bind9.c
index 872eb3e0c1f48a854dd831a3af6928569c11aa6e..9e4a3695866351fef3ca3ec6ad0342323f4c5cfe 100644 (file)
@@ -554,10 +554,12 @@ static isc_result_t parse_options(struct dlz_bind9_data *state,
                default:
                        state->log(ISC_LOG_ERROR, "dlz_bind9: Invalid option %s: %s",
                                   poptBadOption(pc, 0), poptStrerror(opt));
+                       poptFreeContext(pc);
                        return ISC_R_FAILURE;
                }
        }
 
+       poptFreeContext(pc);
        return ISC_R_SUCCESS;
 }