From: Maxim Dounin Date: Mon, 4 Dec 2017 14:30:02 +0000 (+0300) Subject: Autoindex: discard request body (ticket #1439). X-Git-Url: http://www.kaiwu.me/postgresql/commit/?a=commitdiff_plain;h=53e5a746bff6860607d0afced9de9854ad62c50f;p=nginx.git Autoindex: discard request body (ticket #1439). --- diff --git a/src/http/modules/ngx_http_autoindex_module.c b/src/http/modules/ngx_http_autoindex_module.c index b3bf65286..94b91db80 100644 --- a/src/http/modules/ngx_http_autoindex_module.c +++ b/src/http/modules/ngx_http_autoindex_module.c @@ -180,6 +180,12 @@ ngx_http_autoindex_handler(ngx_http_request_t *r) return NGX_DECLINED; } + rc = ngx_http_discard_request_body(r); + + if (rc != NGX_OK) { + return rc; + } + /* NGX_DIR_MASK_LEN is lesser than NGX_HTTP_AUTOINDEX_PREALLOCATE */ last = ngx_http_map_uri_to_path(r, &path, &root,