Remove sometimes erroneous duplicate Content-encoding header for gzip.
authorBrion Vibber <brion@users.mediawiki.org>
Sat, 10 Jan 2004 19:42:33 +0000 (19:42 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Sat, 10 Jan 2004 19:42:33 +0000 (19:42 +0000)
As workaround for Apache2+PHP bug, avoid calling flush() in OutputPage::output
so headers aren't eaten during cache save.

includes/Article.php
includes/OutputPage.php

index 7b122d1..522616d 100644 (file)
@@ -1166,13 +1166,6 @@ class Article {
                                return true;
                        } else {
                                wfDebug( " tryFileCache() - starting buffer\n" );                       
-                               if($cache->useGzip() && wfClientAcceptsGzip()) {
-                                       /* For some reason, adding this header line over in
-                                          CacheManager::saveToFileCache() fails on my test
-                                          setup at home, though it works on the live install.
-                                          Make double-sure...  --brion */
-                                       header( "Content-Encoding: gzip" );
-                               }
                                ob_start( array(&$cache, 'saveToFileCache' ) );
                        }
                } else {
index 6b8aec6..307148a 100644 (file)
@@ -284,7 +284,7 @@ class OutputPage {
                }
 
                $sk->outputPage( $this );
-               flush();
+               flush();
        }
 
        function out( $ins )