Index: trunk/phase3/includes/OutputPage.php |
— | — | @@ -233,6 +233,7 @@ |
234 | 234 | # Not modified |
235 | 235 | # Give a 304 response code and disable body output |
236 | 236 | wfDebug( __METHOD__ . ": NOT MODIFIED, $info\n", false ); |
| 237 | + ini_set('zlib.output_compression', 0); |
237 | 238 | $wgRequest->response()->header( "HTTP/1.1 304 Not Modified" ); |
238 | 239 | $this->sendCacheControl(); |
239 | 240 | $this->disable(); |
Index: trunk/phase3/includes/StreamFile.php |
— | — | @@ -48,6 +48,7 @@ |
49 | 49 | $modsince = preg_replace( '/;.*$/', '', $_SERVER['HTTP_IF_MODIFIED_SINCE'] ); |
50 | 50 | $sinceTime = strtotime( $modsince ); |
51 | 51 | if ( $stat['mtime'] <= $sinceTime ) { |
| 52 | + ini_set('zlib.output_compression', 0); |
52 | 53 | header( "HTTP/1.0 304 Not Modified" ); |
53 | 54 | return; |
54 | 55 | } |
Index: trunk/phase3/includes/AjaxResponse.php |
— | — | @@ -178,6 +178,7 @@ |
179 | 179 | wfDebug( "$fname: -- client send If-Modified-Since: " . $modsince . "\n", false ); |
180 | 180 | wfDebug( "$fname: -- we might send Last-Modified : $lastmod\n", false ); |
181 | 181 | if( ($ismodsince >= $timestamp ) && $wgUser->validateCache( $ismodsince ) && $ismodsince >= $wgCacheEpoch ) { |
| 182 | + ini_set('zlib.output_compression', 0); |
182 | 183 | $this->setResponseCode( "304 Not Modified" ); |
183 | 184 | $this->disable(); |
184 | 185 | $this->mLastModified = $lastmod; |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -277,6 +277,7 @@ |
278 | 278 | * (bug 11487) Special:Protectedpages doesn't list protections with pr_expiry |
279 | 279 | IS NULL |
280 | 280 | * (bug 18018) Deleting a file redirect leaves behind a malfunctioning redirect |
| 281 | +* (bug 17537) Disable bad zlib.output_compression output on HTTP 304 responses |
281 | 282 | |
282 | 283 | == API changes in 1.15 == |
283 | 284 | * (bug 16858) Revamped list=deletedrevs to make listing deleted contributions |