You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bugs@httpd.apache.org by bu...@apache.org on 2003/05/14 09:09:23 UTC

DO NOT REPLY [Bug 19913] New: - mod_deflate: "r->content_encoding" should be checked

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=19913>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=19913

mod_deflate: "r->content_encoding" should be checked

           Summary: mod_deflate: "r->content_encoding" should be checked
           Product: Apache httpd-2.0
           Version: HEAD
          Platform: PC
        OS/Version: Solaris
            Status: NEW
          Severity: Minor
          Priority: Other
         Component: mod_deflate
        AssignedTo: bugs@httpd.apache.org
        ReportedBy: nazonazo@super.win.ne.jp


"r->content_encoding" should be checked to avoid compressing a compressed file,
when an internal redirection occurs by mod_negotiation/mod_rewrite,
or "*.{html,txt,etc}.gz" is requested directly.

--- httpd-2.0/modules/filters/mod_deflate.c     Wed Mar 12 03:11:33 2003
+++ httpd-2.0/modules/filters/mod_deflate.c     Wed May 14 14:55:40 2003
@@ -340,6 +340,12 @@
             encoding = apr_table_get(r->err_headers_out, "Content-Encoding");
         }
 
+        if (r->content_encoding) {
+            encoding = encoding ? apr_pstrcat(r->pool, encoding, ",",
+                                              r->content_encoding, NULL)
+                                : r->content_encoding;
+        }
+
         if (encoding) {
             const char *tmp = encoding;

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org