aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2009-07-27 13:14:45 +0000
committerIgor Sysoev <igor@sysoev.ru>2009-07-27 13:14:45 +0000
commitce1ba38b936ac4320ea3dfc21dc2ed6d777bfb90 (patch)
tree3a63330f1f565d1de3f4af262c166a79efff7bc0
parent7335dfa4b628ba30018605d570bbc9fd89934d3f (diff)
downloadnginx-ce1ba38b936ac4320ea3dfc21dc2ed6d777bfb90.tar.gz
nginx-ce1ba38b936ac4320ea3dfc21dc2ed6d777bfb90.zip
fix handling "Last-Modified" and "Accept-Ranges" for upstream responses
-rw-r--r--src/http/ngx_http_upstream.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/http/ngx_http_upstream.c b/src/http/ngx_http_upstream.c
index e37019609..a8cf07fa8 100644
--- a/src/http/ngx_http_upstream.c
+++ b/src/http/ngx_http_upstream.c
@@ -3301,10 +3301,11 @@ ngx_http_upstream_copy_last_modified(ngx_http_request_t *r, ngx_table_elt_t *h,
*ho = *h;
+ r->headers_out.last_modified = ho;
+
#if (NGX_HTTP_CACHE)
if (r->upstream->cacheable) {
- r->headers_out.last_modified = ho;
r->headers_out.last_modified_time = ngx_http_parse_time(h->value.data,
h->value.len);
}
@@ -3428,6 +3429,8 @@ ngx_http_upstream_copy_allow_ranges(ngx_http_request_t *r,
*ho = *h;
+ r->headers_out.accept_ranges = ho;
+
return NGX_OK;
}