Mercurial > hg > nginx
comparison src/core/ngx_hunk.h @ 147:be71fca7f9d7
nginx-0.0.1-2003-10-14-19:06:38 import
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Tue, 14 Oct 2003 15:06:38 +0000 |
parents | 58557d0cccd1 |
children | 5afee0074707 |
comparison
equal
deleted
inserted
replaced
146:5ac79e574285 | 147:be71fca7f9d7 |
---|---|
83 | 83 |
84 #define ngx_hunk_special(h) \ | 84 #define ngx_hunk_special(h) \ |
85 (h->type == (h->type & (NGX_HUNK_FLUSH|NGX_HUNK_LAST))) | 85 (h->type == (h->type & (NGX_HUNK_FLUSH|NGX_HUNK_LAST))) |
86 | 86 |
87 | 87 |
88 #define nxg_hunk_size(h) \ | |
89 (h->type & NGX_HUNK_IN_MEMORY) ? h->last - h->pos: \ | |
90 (size_t) h->file_last - h->file_pos | |
91 | |
92 | |
88 ngx_hunk_t *ngx_create_temp_hunk(ngx_pool_t *pool, int size, | 93 ngx_hunk_t *ngx_create_temp_hunk(ngx_pool_t *pool, int size, |
89 int before, int after); | 94 int before, int after); |
90 | 95 |
91 #define ngx_alloc_hunk(pool) ngx_palloc(pool, sizeof(ngx_hunk_t)) | 96 #define ngx_alloc_hunk(pool) ngx_palloc(pool, sizeof(ngx_hunk_t)) |
92 #define ngx_calloc_hunk(pool) ngx_pcalloc(pool, sizeof(ngx_hunk_t)) | 97 #define ngx_calloc_hunk(pool) ngx_pcalloc(pool, sizeof(ngx_hunk_t)) |