]> git.ipfire.org Git - thirdparty/dhcp.git/commitdiff
[master] Added null check to eliminate call to dfree in lc_delete_all
authorThomas Markwalder <tmark@isc.org>
Tue, 27 Sep 2016 18:59:08 +0000 (14:59 -0400)
committerThomas Markwalder <tmark@isc.org>
Tue, 27 Sep 2016 18:59:08 +0000 (14:59 -0400)
    Merges in rt43262.

RELNOTES
server/leasechain.c

index f02df24b6dd20033b9d7e02168413aaa7fb52be3..e4d6eb8832da821f50ec10ffc6b32590756e3bb9 100644 (file)
--- a/RELNOTES
+++ b/RELNOTES
@@ -88,6 +88,12 @@ by Eric Young (eay@cryptsoft.com).
   either "no" or an (absolute) path, i.e. "yes" is no longer valid.
   [ISC-Bugs #43227]
 
+- Eliminated a noisy, but otherwise harmless debug log statment that may
+  appear during server startup when building with --enable-binary-leases
+  and configuring multiple pools in a shared network.  Thanks to Fernando
+  Soto from BlueCat Networks for reporting the issue and supplying a patch.
+  [ISC-Bugs #43262]
+
                        Changes since 4.3.0 (bug fixes)
 
 - Tidy up several small tickets.
index bf6a2bf94c8a8cc907cace151b03647b6f3c46f7..11310a922fdd4f5f823a828d643da2c8a56d56ee 100644 (file)
@@ -670,8 +670,11 @@ lc_delete_all(struct leasechain *lc) {
        }
 
        /* and then get rid of the list itself */
-       dfree(lc->list, MDL);
-       lc->list = NULL;
+       if (lc->list != NULL) {
+               dfree(lc->list, MDL);
+               lc->list = NULL;
+       }
+
        lc->total = 0;
        lc->nelem = 0;
 }