diff options
author | Igor Sysoev <igor@sysoev.ru> | 2008-06-17 15:00:30 +0000 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2008-06-17 15:00:30 +0000 |
commit | 7f6b2ffc60135a8340213fe8d5d0b70e479e3ac1 (patch) | |
tree | 90325238fc9a9d9a7e8818e76b60cc9e011242aa /src/core/ngx_cycle.c | |
parent | c2eb2cf4cba5f47fbc33eebe279f0d3855401421 (diff) | |
download | nginx-7f6b2ffc60135a8340213fe8d5d0b70e479e3ac1.tar.gz nginx-7f6b2ffc60135a8340213fe8d5d0b70e479e3ac1.zip |
*) back out r2040
*) refactor ngx_palloc()
*) introduce ngx_pnalloc()
*) additional pool blocks have smaller header
Diffstat (limited to 'src/core/ngx_cycle.c')
-rw-r--r-- | src/core/ngx_cycle.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/core/ngx_cycle.c b/src/core/ngx_cycle.c index 9cdbb2d95..a82e8506b 100644 --- a/src/core/ngx_cycle.c +++ b/src/core/ngx_cycle.c @@ -81,7 +81,7 @@ ngx_init_cycle(ngx_cycle_t *old_cycle) cycle->conf_file.len = old_cycle->conf_file.len; - cycle->conf_file.data = ngx_palloc(pool, old_cycle->conf_file.len + 1); + cycle->conf_file.data = ngx_pnalloc(pool, old_cycle->conf_file.len + 1); if (cycle->conf_file.data == NULL) { ngx_destroy_pool(pool); return NULL; @@ -182,7 +182,7 @@ ngx_init_cycle(ngx_cycle_t *old_cycle) hostname[NGX_MAXHOSTNAMELEN - 1] = '\0'; cycle->hostname.len = ngx_strlen(hostname); - cycle->hostname.data = ngx_palloc(pool, cycle->hostname.len); + cycle->hostname.data = ngx_pnalloc(pool, cycle->hostname.len); if (cycle->hostname.data == NULL) { ngx_destroy_pool(pool); return NULL; @@ -460,8 +460,8 @@ ngx_init_cycle(ngx_cycle_t *old_cycle) #else - lock_file = ngx_palloc(cycle->pool, - cycle->lock_file.len + shm_zone[i].name.len); + lock_file = ngx_pnalloc(cycle->pool, + cycle->lock_file.len + shm_zone[i].name.len); if (lock_file == NULL) { goto failed; |