mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 06:25:31 +00:00
Destroy the hashmap iterator inside the rwlock
Previously, the hashmap iterator for fetches-per-zone was destroy
outside the rwlock. This could lead to an assertion failure due to a
timing race with the internal rehashing of the hashmap table as the
rehashing process requires no iterators to be running when rehashing the
hashmap table. This has been fixed by moving the destruction of the
iterator inside the read locked section.
(cherry picked from commit 1e4fb53c61
)
This commit is contained in:
@@ -11087,8 +11087,8 @@ dns_resolver_dumpquota(dns_resolver_t *res, isc_buffer_t **buf) {
|
||||
}
|
||||
|
||||
cleanup:
|
||||
RWUNLOCK(&res->counters_lock, isc_rwlocktype_read);
|
||||
isc_hashmap_iter_destroy(&it);
|
||||
RWUNLOCK(&res->counters_lock, isc_rwlocktype_read);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user