Suppressed file not found warning, removed unnecessary cache suppression header
authorTim Starling <tstarling@users.mediawiki.org>
Sat, 13 Aug 2005 07:53:16 +0000 (07:53 +0000)
committerTim Starling <tstarling@users.mediawiki.org>
Sat, 13 Aug 2005 07:53:16 +0000 (07:53 +0000)
includes/StreamFile.php

index 3098ea8..0c44bb9 100644 (file)
@@ -4,7 +4,7 @@
 /** */
 function wfStreamFile( $fname ) {
        global $wgSquidMaxage;
-       $stat = stat( $fname );
+       $stat = @stat( $fname );
        if ( !$stat ) {
                header( 'HTTP/1.0 404 Not Found' );
                echo "<html><body>
@@ -15,7 +15,6 @@ does not.</p>
                return;
        }
 
-       header( "Cache-Control: s-maxage=$wgSquidMaxage, must-revalidate, max-age=0" );
        header( 'Last-Modified: ' . gmdate( 'D, d M Y H:i:s', $stat['mtime'] ) . ' GMT' );
 
        if ( !empty( $_SERVER['HTTP_IF_MODIFIED_SINCE'] ) ) {