mirror of
https://github.com/isc-projects/bind9.git
synced 2026-02-24 02:10:30 -05:00
Global memory context had the wrong name (RT #17932)
This commit is contained in:
parent
1dd74a0744
commit
eeb8892daa
2 changed files with 5 additions and 4 deletions
|
|
@ -15,7 +15,7 @@
|
|||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: main.c,v 1.161 2008/01/18 23:46:57 tbox Exp $ */
|
||||
/* $Id: main.c,v 1.162 2008/04/03 23:14:52 jinmei Exp $ */
|
||||
|
||||
/*! \file */
|
||||
|
||||
|
|
@ -878,6 +878,7 @@ main(int argc, char *argv[]) {
|
|||
if (result != ISC_R_SUCCESS)
|
||||
ns_main_earlyfatal("isc_mem_create() failed: %s",
|
||||
isc_result_totext(result));
|
||||
isc_mem_setname(ns_g_mctx, "main", NULL);
|
||||
|
||||
setup();
|
||||
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: resolver.c,v 1.365 2008/04/03 05:55:52 marka Exp $ */
|
||||
/* $Id: resolver.c,v 1.366 2008/04/03 23:14:52 jinmei Exp $ */
|
||||
|
||||
/*! \file */
|
||||
|
||||
|
|
@ -6505,6 +6505,7 @@ dns_resolver_create(dns_view_t *view,
|
|||
goto cleanup_buckets;
|
||||
}
|
||||
res->buckets[i].mctx = NULL;
|
||||
snprintf(name, sizeof(name), "res%u", i);
|
||||
#ifdef ISC_PLATFORM_USETHREADS
|
||||
/*
|
||||
* Use a separate memory context for each bucket to reduce
|
||||
|
|
@ -6517,12 +6518,11 @@ dns_resolver_create(dns_view_t *view,
|
|||
DESTROYLOCK(&res->buckets[i].lock);
|
||||
goto cleanup_buckets;
|
||||
}
|
||||
isc_mem_setname(res->buckets[i].mctx, name, NULL);
|
||||
#else
|
||||
isc_mem_attach(view->mctx, &res->buckets[i].mctx);
|
||||
#endif
|
||||
snprintf(name, sizeof(name), "res%u", i);
|
||||
isc_task_setname(res->buckets[i].task, name, res);
|
||||
isc_mem_setname(res->buckets[i].mctx, name, NULL);
|
||||
ISC_LIST_INIT(res->buckets[i].fctxs);
|
||||
res->buckets[i].exiting = ISC_FALSE;
|
||||
buckets_created++;
|
||||
|
|
|
|||
Loading…
Reference in a new issue