]> git.kaiwu.me - nginx.git/commitdiff
Request body: fixed r->count increment on allocation failure.
authorMaxim Dounin <mdounin@mdounin.ru>
Sat, 11 May 2013 14:49:19 +0000 (18:49 +0400)
committerMaxim Dounin <mdounin@mdounin.ru>
Sat, 11 May 2013 14:49:19 +0000 (18:49 +0400)
src/http/ngx_http_request_body.c

index 2c612311d0a65b6e3fab06d2c21822edf98b6247..7ca328791fe5fc10ff97628332b3b11645568cc2 100644 (file)
@@ -152,7 +152,8 @@ ngx_http_read_client_request_body(ngx_http_request_t *r,
 
             cl = ngx_chain_get_free_buf(r->pool, &rb->free);
             if (cl == NULL) {
-                return NGX_HTTP_INTERNAL_SERVER_ERROR;
+                rc = NGX_HTTP_INTERNAL_SERVER_ERROR;
+                goto done;
             }
 
             b = cl->buf;