]> git.kaiwu.me - nginx.git/commitdiff
Allowed add_header for proxied 206 replies.
authorMaxim Dounin <mdounin@mdounin.ru>
Mon, 28 Nov 2011 10:00:47 +0000 (10:00 +0000)
committerMaxim Dounin <mdounin@mdounin.ru>
Mon, 28 Nov 2011 10:00:47 +0000 (10:00 +0000)
It was working for nginx's own 206 replies as they are seen as 200 in the
headers filter module (range filter goes later in the headers filter chain),
but not for proxied replies.

src/http/modules/ngx_http_headers_filter_module.c

index c846c5fea97a42e219d7702fddabc0da0eecf8e8..754473355ccab628afb5efa8bdc4453ea62078cd 100644 (file)
@@ -145,6 +145,7 @@ ngx_http_headers_filter(ngx_http_request_t *r)
         || r != r->main
         || (r->headers_out.status != NGX_HTTP_OK
             && r->headers_out.status != NGX_HTTP_NO_CONTENT
+            && r->headers_out.status != NGX_HTTP_PARTIAL_CONTENT
             && r->headers_out.status != NGX_HTTP_MOVED_PERMANENTLY
             && r->headers_out.status != NGX_HTTP_MOVED_TEMPORARILY
             && r->headers_out.status != NGX_HTTP_NOT_MODIFIED))