aboutsummaryrefslogtreecommitdiff
path: root/src/http
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2004-09-21 15:47:05 +0000
committerIgor Sysoev <igor@sysoev.ru>2004-09-21 15:47:05 +0000
commit4624ae7d0831f836529acb57a8c3ce6199e67d6e (patch)
tree6e91ac82ffc27438d1db013c45815fea5e759ef7 /src/http
parentdd888c4caadfbd94c595e6e39bdb361de82dda9f (diff)
downloadnginx-4624ae7d0831f836529acb57a8c3ce6199e67d6e.tar.gz
nginx-4624ae7d0831f836529acb57a8c3ce6199e67d6e.zip
nginx-0.0.11-2004-09-21-19:47:05 import
Diffstat (limited to 'src/http')
-rw-r--r--src/http/modules/ngx_http_gzip_filter.c9
-rw-r--r--src/http/ngx_http_request.h12
2 files changed, 13 insertions, 8 deletions
diff --git a/src/http/modules/ngx_http_gzip_filter.c b/src/http/modules/ngx_http_gzip_filter.c
index dc101b7fc..1a373784d 100644
--- a/src/http/modules/ngx_http_gzip_filter.c
+++ b/src/http/modules/ngx_http_gzip_filter.c
@@ -440,8 +440,9 @@ static ngx_int_t ngx_http_gzip_body_filter(ngx_http_request_t *r,
* Besides we free this memory as soon as the gzipping will complete
* and do not wait while a whole response will be sent to a client.
*
- * 8K is for zlib deflate_state. It takes 5816 bytes on x86
- * and 5920 bytes on amd64.
+ * 8K is for zlib deflate_state, it takes
+ * * 5816 bytes on x86 and sparc64 (32-bit mode)
+ * * 5920 bytes on amd64 and sparc64
*/
ctx->allocated = 8192 + (1 << (wbits + 2)) + (1 << (memlevel + 9));
@@ -803,9 +804,7 @@ static void *ngx_http_gzip_filter_alloc(void *opaque, u_int items, u_int size)
if (alloc % 512 != 0) {
/*
- * The zlib deflate_state allocation, it takes 5816 bytes on x86
- * and 5920 bytes on amd64.
- * We allocate 8K.
+ * the zlib deflate_state allocation, it takes about 6K, we allocate 8K
*/
alloc = (alloc + ngx_pagesize - 1) & ~(ngx_pagesize - 1);
diff --git a/src/http/ngx_http_request.h b/src/http/ngx_http_request.h
index 4dd1e82ee..8ecdfd11f 100644
--- a/src/http/ngx_http_request.h
+++ b/src/http/ngx_http_request.h
@@ -218,9 +218,15 @@ struct ngx_http_cleanup_s {
typedef struct {
- ngx_http_request_t *request;
- ngx_array_t large_buffers;
- ngx_uint_t pipeline; /* unsigned pipeline:1; */
+ ngx_http_request_t *request;
+
+ ngx_buf_t **busy;
+ ngx_uint_t nbusy;
+
+ ngx_buf_t **free;
+ ngx_uint_t nfree;
+
+ ngx_uint_t pipeline; /* unsigned pipeline:1; */
} ngx_http_connection_t;