Autoindex: discard request body (ticket #1439).

This commit is contained in:
Maxim Dounin 2017-12-04 17:30:02 +03:00
parent 18fdb9ae02
commit 3cdd70d9f5
1 changed files with 6 additions and 0 deletions

View File

@ -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,