aboutsummaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2003-10-14 15:06:38 +0000
committerIgor Sysoev <igor@sysoev.ru>2003-10-14 15:06:38 +0000
commite4aabac04e078f07dce73e90847ef02d74facbe2 (patch)
tree929e0d280e0c7b8ee045271dab45b3eb803a85e8 /src/core
parent1be6fcf207cec24e3a1e64d383efac4de3d0e5c3 (diff)
downloadnginx-e4aabac04e078f07dce73e90847ef02d74facbe2.tar.gz
nginx-e4aabac04e078f07dce73e90847ef02d74facbe2.zip
nginx-0.0.1-2003-10-14-19:06:38 import
Diffstat (limited to 'src/core')
-rw-r--r--src/core/ngx_hunk.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/core/ngx_hunk.h b/src/core/ngx_hunk.h
index a5bdfcb38..a66d47610 100644
--- a/src/core/ngx_hunk.h
+++ b/src/core/ngx_hunk.h
@@ -85,6 +85,11 @@ typedef struct {
(h->type == (h->type & (NGX_HUNK_FLUSH|NGX_HUNK_LAST)))
+#define nxg_hunk_size(h) \
+ (h->type & NGX_HUNK_IN_MEMORY) ? h->last - h->pos: \
+ (size_t) h->file_last - h->file_pos
+
+
ngx_hunk_t *ngx_create_temp_hunk(ngx_pool_t *pool, int size,
int before, int after);