From 63a5f5fe2c2f83cd8a52328dd936f4a5969e6494 Mon Sep 17 00:00:00 2001 From: Martin Nagy Date: Wed, 22 Apr 2009 16:00:14 +0200 Subject: Unload plug-ins from last to first. --- lib/dns/dynamic_db.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/dns/dynamic_db.c b/lib/dns/dynamic_db.c index 5dc9644..de2daf7 100644 --- a/lib/dns/dynamic_db.c +++ b/lib/dns/dynamic_db.c @@ -229,18 +229,18 @@ void dns_dynamic_db_cleanup(isc_boolean_t exiting) { dyndb_implementation_t *elem; - dyndb_implementation_t *next; + dyndb_implementation_t *prev; RUNTIME_CHECK(isc_once_do(&once, dyndb_initialize) == ISC_R_SUCCESS); LOCK(&dyndb_lock); - elem = HEAD(dyndb_implementations); + elem = TAIL(dyndb_implementations); while (elem != NULL) { - next = NEXT(elem, link); + prev = PREV(elem, link); UNLINK(dyndb_implementations, elem, link); elem->destroy_function(); unload_library(&elem); - elem = next; + elem = prev; } UNLOCK(&dyndb_lock); -- cgit