Don't do gzip compression if the URL path ends in .gz or .tgz
authorBrion Vibber <brion@users.mediawiki.org>
Thu, 19 Jul 2007 19:06:32 +0000 (19:06 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Thu, 19 Jul 2007 19:06:32 +0000 (19:06 +0000)
commitf4080c18382721a1c351b1913a17b0e1ea66af86
tree937de514c67108c28898d625e5082163b6651ffd
parentee30721d8bc5b157100feeb3a5c64c1f14c23ef3
Don't do gzip compression if the URL path ends in .gz or .tgz
This confuses Safari and triggers a download of the page,
even though it's pretty clearly labeled as viewable HTML.
Bad Safari! Bad!

Bug is still present in Safari 2.0.4/Mac and 3.0.2/Win.

We have had a live hack for this on Wikimedia sites for .gz files;
hadn't noticed the .tgz problem before though.

While I was in there, also made a tweak so wfGzipHandler() makes
sure the Vary: header is there whether the current agent sent us
an Accept-Encoding header or not.
RELEASE-NOTES
includes/OutputHandler.php