Since there could be fetches running, we need to run expire_name() under
the lock when shutting down the names.
name = next)
{
next = ISC_LIST_NEXT(name, link);
+ dns_adbname_ref(name);
+ LOCK(&name->lock);
/*
* Run through the list. For each name, clean up finds
* found there, and cancel any fetches running. When
* itself.
*/
expire_name(name, DNS_EVENT_ADBSHUTDOWN, INT_MAX);
+ UNLOCK(&name->lock);
+ dns_adbname_detach(&name);
}
UNLOCK(&adb->names_lock);
}