]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Remove redundant check for listener being non-NULL
authorMark Andrews <marka@isc.org>
Mon, 6 Jul 2020 03:16:33 +0000 (13:16 +1000)
committerMark Andrews <marka@isc.org>
Mon, 13 Jul 2020 00:28:34 +0000 (10:28 +1000)
(cherry picked from commit c91dc92410f15d1c93c70d2c596350eee7748958)

bin/named/controlconf.c

index 26f80423f2933e79c04038c0669731a707017477..e48b76f3777e00d06a6db7ad8e77e9145c475f7d 100644 (file)
@@ -1256,10 +1256,8 @@ add_listener(named_controls_t *cp, controllistener_t **listenerp,
                              "command channel listening on %s", socktext);
                *listenerp = listener;
        } else {
-               if (listener != NULL) {
-                       listener->exiting = true;
-                       free_listener(listener);
-               }
+               listener->exiting = true;
+               free_listener(listener);
 
                if (control != NULL) {
                        cfg_obj_log(control, named_g_lctx, ISC_LOG_WARNING,