updated patches/nginx-1.0.8-allow_request_body_updating.patch to fix the case when calling ngx_http_read_client_request_body after ngx_http_discard_request_body is called.
This commit is contained in:
parent
b0cfa8da4f
commit
b8be9ddfa7
|
@ -1,6 +1,15 @@
|
|||
diff -ur nginx-1.0.8/src/http/ngx_http_request_body.c nginx-1.0.8-patched/src/http/ngx_http_request_body.c
|
||||
--- nginx-1.0.8/src/http/ngx_http_request_body.c 2011-09-30 22:36:19.000000000 +0800
|
||||
+++ nginx-1.0.8-patched/src/http/ngx_http_request_body.c 2011-10-21 19:05:53.954380165 +0800
|
||||
+++ nginx-1.0.8-patched/src/http/ngx_http_request_body.c 2011-10-21 21:54:08.460350482 +0800
|
||||
@@ -38,7 +38,7 @@
|
||||
|
||||
r->main->count++;
|
||||
|
||||
- if (r->request_body || r->discard_body) {
|
||||
+ if (r->request_body || r->discard_body || r->content_length_n == 0) {
|
||||
post_handler(r);
|
||||
return NGX_OK;
|
||||
}
|
||||
@@ -440,7 +440,7 @@
|
||||
ssize_t size;
|
||||
ngx_event_t *rev;
|
||||
|
|
|
@ -581,7 +581,6 @@ _END_
|
|||
ngx_lua_dquote='"'
|
||||
CFLAGS="\$CFLAGS -DLUA_DEFAULT_PATH='\$ngx_lua_dquote$lualib_prefix/?.lua\$ngx_lua_dquote'"
|
||||
CFLAGS="\$CFLAGS -DLUA_DEFAULT_CPATH='\$ngx_lua_dquote$lualib_prefix/?.so\$ngx_lua_dquote'"
|
||||
CFLAGS="\$CFLAGS -DNGINX_ALLOW_REQUEST_BODY_UPDATING"
|
||||
_EOC_
|
||||
|
||||
close $in;
|
||||
|
|
Loading…
Reference in New Issue