]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Do not fail on NULL passed to OpenSSL_free
authorPetr Menšík <pemensik@redhat.com>
Fri, 25 Jan 2019 20:47:37 +0000 (21:47 +0100)
committerEvan Hunt <each@isc.org>
Tue, 29 Jan 2019 23:23:57 +0000 (18:23 -0500)
Some plugins might call it after deconstruction. Do not crash if there
is no reason for it.

CHANGES
lib/dns/openssl_link.c

diff --git a/CHANGES b/CHANGES
index a8504d88d014b71ef8395c30d63749968f8788a3..7694c855c85a2823fb964848a5474754d4b5430b 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,7 @@
+5146.  [bug]           Removed an unnecessary assert that could be
+                       triggered from PKCS#11 modules during
+                       deconstruction. [GL #841]
+
 5143.  [bug]           dnssec-keymgr and dnssec-coverage failed to find
                        key files for zone names ending in ".". [GL #560]
 
index c9926ec6df8714af5a3b9755edb58532e9d1ebbf..1350810190e9af44a9a86018b364c762f44fec8d 100644 (file)
@@ -163,9 +163,11 @@ mem_alloc(size_t size FLARG) {
 
 static void
 mem_free(void *ptr FLARG) {
-       INSIST(dst__memory_pool != NULL);
-       if (ptr != NULL)
+       if (ptr != NULL) {
+               INSIST(dst__memory_pool != NULL);
+
                isc__mem_free(dst__memory_pool, ptr FLARG_PASS);
+       }
 }
 
 static void *