From: Igor Sysoev Date: Mon, 10 Mar 2008 14:36:42 +0000 (+0000) Subject: do not change method while error redirection to named location X-Git-Tag: release-0.6.27~6 X-Git-Url: http://git.kaiwu.me/postgresql/log/contrib/postgres_fdw/postgres_fdw.c?a=commitdiff_plain;h=15a20079a5c0619510fa2bbc73abbd38976d5f67;p=nginx.git do not change method while error redirection to named location --- diff --git a/src/http/ngx_http_special_response.c b/src/http/ngx_http_special_response.c index 5671f9bb7..741a9b1d4 100644 --- a/src/http/ngx_http_special_response.c +++ b/src/http/ngx_http_special_response.c @@ -439,9 +439,6 @@ ngx_http_send_error_page(ngx_http_request_t *r, ngx_http_err_page_t *err_page) r->err_status = err_page->overwrite; - r->method = NGX_HTTP_GET; - r->method_name = ngx_http_get_name; - r->zero_in_uri = 0; args = NULL; @@ -494,6 +491,10 @@ ngx_http_send_error_page(ngx_http_request_t *r, ngx_http_err_page_t *err_page) } if (uri->data[0] == '/') { + + r->method = NGX_HTTP_GET; + r->method_name = ngx_http_get_name; + return ngx_http_internal_redirect(r, uri, args); }