s4: free popt context in dnsserver
authorSwen Schillig <swen@linux.ibm.com>
Mon, 19 Aug 2019 12:33:33 +0000 (14:33 +0200)
committerAndrew Bartlett <abartlet@samba.org>
Thu, 22 Aug 2019 00:21:51 +0000 (00:21 +0000)
If done with popt context it should be free'd.

Signed-off-by: Swen Schillig <swen@linux.ibm.com>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Ralph Böhme <slow@samba.org>
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;
 }