comparison src/http/ngx_http_upstream.c @ 6334:b31928ca3870

Upstream: fixed changing method on X-Accel-Redirect. Previously, only r->method was changed, resulting in handling of a request as GET within nginx itself, but not in requests to proxied servers. See http://mailman.nginx.org/pipermail/nginx/2015-December/049518.html.
author Maxim Dounin <mdounin@mdounin.ru>
date Mon, 11 Jan 2016 19:08:12 +0300
parents 78b4e10b4367
children cf5e822cf470
comparison
equal deleted inserted replaced
6333:9d06921918af 6334:b31928ca3870
2497 return NGX_DONE; 2497 return NGX_DONE;
2498 } 2498 }
2499 2499
2500 if (r->method != NGX_HTTP_HEAD) { 2500 if (r->method != NGX_HTTP_HEAD) {
2501 r->method = NGX_HTTP_GET; 2501 r->method = NGX_HTTP_GET;
2502 r->method_name = ngx_http_core_get_method;
2502 } 2503 }
2503 2504
2504 ngx_http_internal_redirect(r, &uri, &args); 2505 ngx_http_internal_redirect(r, &uri, &args);
2505 } 2506 }
2506 2507