summaryrefslogtreecommitdiffhomepage
path: root/src/nxt_php_sapi.c
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2017-06-20 19:49:17 +0300
committerIgor Sysoev <igor@sysoev.ru>2017-06-20 19:49:17 +0300
commitf888a5310c1808902b4035ca3454b62bc5cf4434 (patch)
tree7425e11cdba27420d21468b0f79787834bd3c498 /src/nxt_php_sapi.c
parentc7ab908c19242a5ddd0233e123e8c2be210b3c02 (diff)
downloadunit-f888a5310c1808902b4035ca3454b62bc5cf4434.tar.gz
unit-f888a5310c1808902b4035ca3454b62bc5cf4434.tar.bz2
Using new memory pool implementation.
Diffstat (limited to 'src/nxt_php_sapi.c')
-rw-r--r--src/nxt_php_sapi.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/nxt_php_sapi.c b/src/nxt_php_sapi.c
index ece3ec92..147361ed 100644
--- a/src/nxt_php_sapi.c
+++ b/src/nxt_php_sapi.c
@@ -167,7 +167,7 @@ nxt_php_request_init(nxt_app_request_t *r)
{
nxt_php_ctx_t *ctx;
- ctx = nxt_mem_zalloc(r->mem_pool, sizeof(nxt_php_ctx_t));
+ ctx = nxt_mp_zget(r->mem_pool, sizeof(nxt_php_ctx_t));
if (nxt_slow_path(ctx == NULL)) {
return NXT_ERROR;
}
@@ -261,7 +261,7 @@ nxt_php_handler(nxt_app_request_t *r)
#if !ABS_MODE
ctx->script.len = sizeof(root) - 1 + ctx->script_name_len;
- ctx->script.data = nxt_mem_nalloc(r->mem_pool, ctx->script.len + 1);
+ ctx->script.data = nxt_mp_nget(r->mem_pool, ctx->script.len + 1);
if (nxt_slow_path(ctx->script.data == NULL)) {
return NXT_ERROR;
@@ -565,7 +565,7 @@ nxt_php_register_variables(zval *track_vars_array TSRMLS_DC)
ctx->content_length->len, track_vars_array TSRMLS_CC);
}
- var = nxt_mem_nalloc(r->mem_pool, sizeof(prefix) + ctx->max_name + 1);
+ var = nxt_mp_nget(r->mem_pool, sizeof(prefix) + ctx->max_name + 1);
if (nxt_slow_path(var == NULL)) {
return;