summaryrefslogtreecommitdiff
path: root/src/http/ngx_http_request.c
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2009-06-02 16:22:32 +0000
committerJonathan Kolb <jon@b0g.us>2009-06-02 16:22:32 +0000
commit48a71b870032c0787bc31650f3143465a4cd417b (patch)
treecdbc3eed0e6881d3632461f027b2547ab3b12f17 /src/http/ngx_http_request.c
parent8e691fc5d70edca2a685bc341bbef7a097371349 (diff)
downloadnginx-0.8.0.tar.gz
Changes with nginx 0.8.0 02 Jun 2009v0.8.0
*) Feature: the "keepalive_requests" directive. *) Feature: the "limit_rate_after" directive. Thanks to Ivan Debnar. *) Bugfix: XLST filter did not work in subrequests. *) Bugfix: in relative paths handling in nginx/Windows. *) Bugfix: in proxy_store, fastcgi_store, proxy_cache, and fastcgi_cache in nginx/Windows. *) Bugfix: in memory allocation error handling. Thanks to Maxim Dounin and Kirill A. Korinskiy.
Diffstat (limited to 'src/http/ngx_http_request.c')
-rw-r--r--src/http/ngx_http_request.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/http/ngx_http_request.c b/src/http/ngx_http_request.c
index c9c6db729..be5c91cbf 100644
--- a/src/http/ngx_http_request.c
+++ b/src/http/ngx_http_request.c
@@ -259,6 +259,8 @@ ngx_http_init_request(ngx_event_t *rev)
return;
}
+ c->requests++;
+
hc = c->data;
if (hc == NULL) {
@@ -449,13 +451,15 @@ ngx_http_init_request(ngx_event_t *rev)
sizeof(ngx_table_elt_t))
!= NGX_OK)
{
- ngx_http_close_request(r, NGX_HTTP_INTERNAL_SERVER_ERROR);
+ ngx_destroy_pool(r->pool);
+ ngx_http_close_connection(c);
return;
}
r->ctx = ngx_pcalloc(r->pool, sizeof(void *) * ngx_http_max_module);
if (r->ctx == NULL) {
- ngx_http_close_request(r, NGX_HTTP_INTERNAL_SERVER_ERROR);
+ ngx_destroy_pool(r->pool);
+ ngx_http_close_connection(c);
return;
}
@@ -464,7 +468,8 @@ ngx_http_init_request(ngx_event_t *rev)
r->variables = ngx_pcalloc(r->pool, cmcf->variables.nelts
* sizeof(ngx_http_variable_value_t));
if (r->variables == NULL) {
- ngx_http_close_request(r, NGX_HTTP_INTERNAL_SERVER_ERROR);
+ ngx_destroy_pool(r->pool);
+ ngx_http_close_connection(c);
return;
}