From: Mark Andrews Date: Fri, 29 Oct 2021 05:57:16 +0000 (+1100) Subject: 'task' is reported when uninitalised X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f80a474e59af2dd9557afd5259a8e0cdb545fb7c;p=thirdparty%2Fbind9.git 'task' is reported when uninitalised move XTRACE to after 'task' is created so that 'task' is valid --- diff --git a/lib/isc/task.c b/lib/isc/task.c index 2cfe953b339..6f075ebdf78 100644 --- a/lib/isc/task.c +++ b/lib/isc/task.c @@ -210,11 +210,11 @@ isc_task_create_bound(isc_taskmgr_t *manager, unsigned int quantum, REQUIRE(VALID_MANAGER(manager)); REQUIRE(taskp != NULL && *taskp == NULL); - XTRACE("isc_task_create"); - task = isc_mem_get(manager->mctx, sizeof(*task)); *task = (isc_task_t){ 0 }; + XTRACE("isc_task_create"); + isc_taskmgr_attach(manager, &task->manager); if (threadid == -1) {