]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
remove isc_bind9 variable
authorEvan Hunt <each@isc.org>
Thu, 9 Feb 2023 03:28:09 +0000 (19:28 -0800)
committerEvan Hunt <each@isc.org>
Thu, 9 Feb 2023 18:00:13 +0000 (18:00 +0000)
isc_bind9 was a global bool used to indicate whether the library
was being used internally by BIND or by an external caller. external
use is no longer supported, but the variable was retained for use
by dyndb, which needed it only when being built without libtool.
building without libtool is *also* no longer supported, so the variable
can go away.

bin/tests/system/dyndb/driver/driver.c
lib/dns/dyndb.c
lib/dns/include/dns/dyndb.h
lib/isc/Makefile.am
lib/isc/bind9.c [deleted file]
lib/isc/include/isc/bind9.h [deleted file]
lib/isc/include/isc/types.h
lib/isc/lib.c
lib/isc/mem.c

index f4497c9d650d1743f9d4c2318c1d7235fb5e8b6a..7e8a249d3ad352c9c9272a5c7c5cecbd847435c0 100644 (file)
@@ -95,17 +95,6 @@ dyndb_init(isc_mem_t *mctx, const char *name, const char *parameters,
        REQUIRE(name != NULL);
        REQUIRE(dctx != NULL);
 
-       /*
-        * Depending on how dlopen() was called, we may not have
-        * access to named's global namespace, in which case we need
-        * to initialize libisc/libdns
-        */
-       if (dctx->refvar != &isc_bind9) {
-               isc_log_setcontext(dctx->lctx);
-               dns_log_setcontext(dctx->lctx);
-               isc_hash_set_initializer(dctx->hashinit);
-       }
-
        s = isc_mem_strdup(mctx, parameters);
 
        result = isc_commandline_strtoargv(mctx, s, &argc, &argv, 0);
index 63d0a4a95bac7c49cae2d49b7dcfb11577926e35..143b92032198709f3bd7e85e4b9c668cb0b56aaf 100644 (file)
@@ -279,7 +279,6 @@ dns_dyndb_createctx(isc_mem_t *mctx, const void *hashinit, isc_log_t *lctx,
                .loopmgr = loopmgr,
                .hashinit = hashinit,
                .lctx = lctx,
-               .refvar = &isc_bind9,
        };
 
        if (view != NULL) {
index b8490d5f373505bce0cb37cfb4c5438e9990d246..6b3be0e785fd40a32935acf107e6c57bc62c539e 100644 (file)
@@ -41,7 +41,7 @@ struct dns_dyndbctx {
        dns_zonemgr_t *zmgr;
        isc_task_t    *task;
        isc_loopmgr_t *loopmgr;
-       const bool    *refvar;
+       const bool    *refvar; /* unused, but retained for API compatibility */
 };
 
 #define DNS_DYNDBCTX_MAGIC    ISC_MAGIC('D', 'd', 'b', 'c')
index 36665d28504e93f3c5d443250882c8b9f8355b39..8201e71d6a4f4dba9ebe849d9b0ffa3a29a2a9ed 100644 (file)
@@ -15,7 +15,6 @@ libisc_la_HEADERS =                   \
        include/isc/barrier.h           \
        include/isc/base32.h            \
        include/isc/base64.h            \
-       include/isc/bind9.h             \
        include/isc/buffer.h            \
        include/isc/cmocka.h            \
        include/isc/commandline.h       \
@@ -124,7 +123,6 @@ libisc_la_SOURCES =         \
        backtrace.c             \
        base32.c                \
        base64.c                \
-       bind9.c                 \
        commandline.c           \
        condition.c             \
        counter.c               \
diff --git a/lib/isc/bind9.c b/lib/isc/bind9.c
deleted file mode 100644 (file)
index b04e56e..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-/*
- * Copyright (C) Internet Systems Consortium, Inc. ("ISC")
- *
- * SPDX-License-Identifier: MPL-2.0
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, you can obtain one at https://mozilla.org/MPL/2.0/.
- *
- * See the COPYRIGHT file distributed with this work for additional
- * information regarding copyright ownership.
- */
-
-/*! \file */
-
-#include <stdbool.h>
-
-#include <isc/bind9.h>
-
-bool isc_bind9 = true;
diff --git a/lib/isc/include/isc/bind9.h b/lib/isc/include/isc/bind9.h
deleted file mode 100644 (file)
index 38c568e..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-/*
- * Copyright (C) Internet Systems Consortium, Inc. ("ISC")
- *
- * SPDX-License-Identifier: MPL-2.0
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, you can obtain one at https://mozilla.org/MPL/2.0/.
- *
- * See the COPYRIGHT file distributed with this work for additional
- * information regarding copyright ownership.
- */
-
-#pragma once
-
-#include <stdbool.h>
-
-extern bool isc_bind9;
index a3ef04698f3f9be8eb8be6f1a70f06d7729e8606..94aa5f760b00603ecf1e246f8fe4b4cd98229bb7 100644 (file)
@@ -13,7 +13,6 @@
 
 #pragma once
 
-#include <isc/bind9.h>
 #include <isc/result.h>
 
 /*! \file isc/types.h
index daf00a59711fd1c8f8f8a06e40a3f4566a30b40c..c389667bc7ca3d6e882d97fce89b7eb916d5d6f4 100644 (file)
@@ -13,7 +13,6 @@
 
 /*! \file */
 
-#include <isc/bind9.h>
 #include <isc/iterated_hash.h>
 #include <isc/md.h>
 #include <isc/mem.h>
index 7b587642e2d29ce1b1eb55769cf5b1e486002a79..ea66c9c09d11a82dcb4eb5ad5c1f140ca86b5a59 100644 (file)
@@ -22,7 +22,6 @@
 #include <stdlib.h>
 
 #include <isc/align.h>
-#include <isc/bind9.h>
 #include <isc/hash.h>
 #include <isc/magic.h>
 #include <isc/mem.h>