summaryrefslogtreecommitdiffhomepage
path: root/src/http/ngx_http_core_module.c
diff options
context:
space:
mode:
authorMaxim Dounin <mdounin@mdounin.ru>2012-03-05 13:03:39 +0000
committerMaxim Dounin <mdounin@mdounin.ru>2012-03-05 13:03:39 +0000
commit031458770a48be9b0bf5534c70abfc8284f135d7 (patch)
tree53cfe7b3be840ec8fa26356ee53df72a2ee7137e /src/http/ngx_http_core_module.c
parent01f59615400f7449a8b88e9e74a27c2a8b93fb87 (diff)
downloadnginx-031458770a48be9b0bf5534c70abfc8284f135d7.tar.gz
nginx-031458770a48be9b0bf5534c70abfc8284f135d7.tar.bz2
Merge of r4491, r4492:
*) Renamed constants and fixed off-by-one error in "msie_padding on" handling. *) Added support for the 307 Temporary Redirect.
Diffstat (limited to 'src/http/ngx_http_core_module.c')
-rw-r--r--src/http/ngx_http_core_module.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/http/ngx_http_core_module.c b/src/http/ngx_http_core_module.c
index 7a1751d06..a27a70916 100644
--- a/src/http/ngx_http_core_module.c
+++ b/src/http/ngx_http_core_module.c
@@ -1798,8 +1798,11 @@ ngx_http_send_response(ngx_http_request_t *r, ngx_uint_t status,
return NGX_HTTP_INTERNAL_SERVER_ERROR;
}
- if (status >= NGX_HTTP_MOVED_PERMANENTLY && status <= NGX_HTTP_SEE_OTHER) {
-
+ if (status == NGX_HTTP_MOVED_PERMANENTLY
+ || status == NGX_HTTP_MOVED_TEMPORARILY
+ || status == NGX_HTTP_SEE_OTHER
+ || status == NGX_HTTP_TEMPORARY_REDIRECT)
+ {
ngx_http_clear_location(r);
r->headers_out.location = ngx_list_push(&r->headers_out.headers);