if (r == r->main) {
- if (r->headers_out.content_encoding
+ if (!r->ignore_content_encoding
+ && r->headers_out.content_encoding
&& r->headers_out.content_encoding->value.len)
{
return ngx_http_next_header_filter(r);
h->value.data = (u_char *) "gzip";
r->headers_out.content_encoding = h;
+ r->ignore_content_encoding = 1;
/* we need to allocate all before the header would be sent */
unsigned discard_body:1;
unsigned internal:1;
unsigned error_page:1;
+ unsigned ignore_content_encoding:1;
unsigned filter_finalize:1;
unsigned post_action:1;
unsigned request_complete:1;