diff options
Diffstat (limited to 'src/nxt_list.c')
-rw-r--r-- | src/nxt_list.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nxt_list.c b/src/nxt_list.c index 6ba7c9fa..9a44ce9a 100644 --- a/src/nxt_list.c +++ b/src/nxt_list.c @@ -8,11 +8,11 @@ nxt_list_t * -nxt_list_create(nxt_mem_pool_t *mp, nxt_uint_t n, size_t size) +nxt_list_create(nxt_mp_t *mp, nxt_uint_t n, size_t size) { nxt_list_t *list; - list = nxt_mem_alloc(mp, sizeof(nxt_list_t) + n * size); + list = nxt_mp_get(mp, sizeof(nxt_list_t) + n * size); if (nxt_fast_path(list != NULL)) { list->last = &list->part; @@ -39,8 +39,8 @@ nxt_list_add(nxt_list_t *list) /* The last list part is filled up, allocating a new list part. */ - last = nxt_mem_alloc(list->mem_pool, - sizeof(nxt_list_part_t) + list->nalloc * list->size); + last = nxt_mp_get(list->mem_pool, + sizeof(nxt_list_part_t) + list->nalloc * list->size); if (nxt_slow_path(last == NULL)) { return NULL; |