From: Rainer Jung Date: Fri, 20 Mar 2009 17:38:39 +0000 (+0000) Subject: Set the content encoding for compressed content X-Git-Tag: 2.3.2~7 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=33352114d05c4c64e8461d1d83e82c8990434a67;p=thirdparty%2Fapache%2Fhttpd.git Set the content encoding for compressed content even if we can't detect the content type of the uncompressed content. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@756678 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/modules/metadata/mod_mime_magic.c b/modules/metadata/mod_mime_magic.c index 96ac989ae9c..cd7b491a6ff 100644 --- a/modules/metadata/mod_mime_magic.c +++ b/modules/metadata/mod_mime_magic.c @@ -2100,12 +2100,12 @@ static int zmagic(request_rec *r, unsigned char *buf, apr_size_t nbytes) return 0; if ((newsize = uncompress(r, i, &newbuf, nbytes)) > 0) { + /* set encoding type in the request record */ + r->content_encoding = compr[i].encoding; + if (tryit(r, newbuf, newsize, 0) != OK) { return 0; } - - /* set encoding type in the request record */ - r->content_encoding = compr[i].encoding; } return 1; }