cancel discarding body on EOF
diff --git a/src/http/ngx_http_request_body.c b/src/http/ngx_http_request_body.c index 1ebb2e5..9c34b7c 100644 --- a/src/http/ngx_http_request_body.c +++ b/src/http/ngx_http_request_body.c
@@ -571,6 +571,10 @@ return NGX_AGAIN; } + if (n == 0) { + return NGX_OK; + } + r->headers_in.content_length_n -= n; } while (r->connection->read->ready);