From 1160ecfd146301ff0d053ed054e5276f33f28b4e Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Wed, 24 Sep 2003 23:20:54 +0000 Subject: [PATCH] 1514. [bug] named: isc_hash_destroy() was being called to early. [RT #9160] --- CHANGES | 3 +++ bin/named/main.c | 10 ++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/CHANGES b/CHANGES index e3b334d6e4..c1a8d34b24 100644 --- a/CHANGES +++ b/CHANGES @@ -1,3 +1,6 @@ +1514. [bug] named: isc_hash_destroy() was being called to early. + [RT #9160] + 1513. [doc] Add "US" to root-delgation-only exclude list. 1512. [bug] Extend the delegation-only logging to return query diff --git a/bin/named/main.c b/bin/named/main.c index ba97646f5d..7260ce149d 100644 --- a/bin/named/main.c +++ b/bin/named/main.c @@ -15,7 +15,7 @@ * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -/* $Id: main.c,v 1.130 2003/07/25 02:22:23 marka Exp $ */ +/* $Id: main.c,v 1.131 2003/09/24 23:20:54 marka Exp $ */ #include @@ -510,7 +510,6 @@ static void destroy_managers(void) { ns_lwresd_shutdown(); - isc_hash_destroy(); isc_entropy_detach(&ns_g_entropy); /* * isc_taskmgr_destroy() will block until all tasks have exited, @@ -518,6 +517,13 @@ destroy_managers(void) { isc_taskmgr_destroy(&ns_g_taskmgr); isc_timermgr_destroy(&ns_g_timermgr); isc_socketmgr_destroy(&ns_g_socketmgr); + + /* + * isc_hash_destroy() cannot be called as long as a resolver may be + * running. Calling this after isc_taskmgr_destroy() ensures the + * call is safe. + */ + isc_hash_destroy(); } static void