diff options
author | Igor Sysoev <igor@sysoev.ru> | 2017-06-19 16:26:19 +0300 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2017-06-19 16:26:19 +0300 |
commit | b1b9f621a44725509aa7b6eab7305542945893a3 (patch) | |
tree | c9925a19d7304f52d9d5e2cc87a5ba5cc72acd4a /src/nxt_router.c | |
parent | 7574c64992b98d3dfbc3dd101bd0f7d78bad0823 (diff) | |
download | unit-b1b9f621a44725509aa7b6eab7305542945893a3.tar.gz unit-b1b9f621a44725509aa7b6eab7305542945893a3.tar.bz2 |
Memory pools refactoring.
Diffstat (limited to 'src/nxt_router.c')
-rw-r--r-- | src/nxt_router.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/nxt_router.c b/src/nxt_router.c index 67acc12d..0d6d58b9 100644 --- a/src/nxt_router.c +++ b/src/nxt_router.c @@ -668,9 +668,10 @@ nxt_router_thread_start(void *data) engine->task.thread = thread; engine->task.log = thread->log; thread->engine = engine; + thread->task = &engine->task; thread->fiber = &engine->fibers->fiber; - engine->mem_pool = nxt_mem_cache_pool_create(4096, 1024, 1024, 64); + engine->mem_pool = nxt_mp_create(4096, 128, 1024, 64); nxt_event_engine_start(engine); } @@ -870,7 +871,7 @@ nxt_router_thread_exit_handler(nxt_task_t *task, void *obj, void *data) nxt_queue_remove(&engine->link); - nxt_mem_cache_pool_destroy(engine->mem_pool); + nxt_mp_destroy(engine->mem_pool); nxt_event_engine_free(engine); |