r9908 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r9907‎ | r9908 | r9909 >
Date:22:06, 4 July 2005
Author:vibber
Status:old
Tags:
Comment:
* Workaround for mysterious problem with bogus epoch If-Last-Modified reqs
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/OutputPage.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/OutputPage.php
@@ -113,7 +113,8 @@
114114 # Wed, 20 Aug 2003 06:51:19 GMT; length=5202
115115 # this breaks strtotime().
116116 $modsince = preg_replace( '/;.*$/', '', $_SERVER["HTTP_IF_MODIFIED_SINCE"] );
117 - $ismodsince = wfTimestamp( TS_MW, strtotime( $modsince ) );
 117+ $modsinceTime = strtotime( $modsince );
 118+ $ismodsince = wfTimestamp( TS_MW, $modsinceTime ? $modsinceTime : 1 );
118119 wfDebug( "-- client send If-Modified-Since: " . $modsince . "\n", false );
119120 wfDebug( "-- we might send Last-Modified : $lastmod\n", false );
120121 if( ($ismodsince >= $timestamp ) && $wgUser->validateCache( $ismodsince ) ) {
Index: trunk/phase3/RELEASE-NOTES
@@ -468,6 +468,7 @@
469469 * Removed language conversion support from Icelandic
470470 * (bug 2616) Fix proportional image scaling, giving correct height
471471 * (bug 2640) Include width and height attributes on unscaled images
 472+* Workaround for mysterious problem with bogus epoch If-Last-Modified reqs
472473
473474
474475 === Caveats ===

Status & tagging log