]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
remove dead cleanup code.
authorMark Andrews <marka@isc.org>
Wed, 5 Feb 2020 05:07:31 +0000 (16:07 +1100)
committerMark Andrews <marka@isc.org>
Wed, 5 Feb 2020 07:37:17 +0000 (18:37 +1100)
13836        if (zone != NULL)
13837                dns_zone_detach(&zone);

      null: At condition dz != NULL, the value of dz must be NULL.
      dead_error_condition: The condition dz != NULL cannot be true.

13838        if (dz != NULL) {

CID 1453456 (#1 of 1): Logically dead code (DEADCODE)
dead_error_begin: Execution cannot reach this statement:
dns_zone_detach(&dz->zone);.

13839                dns_zone_detach(&dz->zone);
13840                isc_mem_put(named_g_mctx, dz, sizeof(*dz));
13841        }

bin/named/server.c

index f7f0f7dd16af417fcf414f609d79a7fdad3aa95a..0af78773b8e88149d626c184ea78a801687a364c 100644 (file)
@@ -13835,10 +13835,6 @@ named_server_delzone(named_server_t *server, isc_lex_t *lex,
                dns_zone_detach(&raw);
        if (zone != NULL)
                dns_zone_detach(&zone);
-       if (dz != NULL) {
-               dns_zone_detach(&dz->zone);
-               isc_mem_put(named_g_mctx, dz, sizeof(*dz));
-       }
 
        return (result);
 }