r112379 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r112378‎ | r112379 | r112380 >
Date:01:00, 25 February 2012
Author:aaron
Status:ok
Tags:
Comment:
Modified paths:
  • /branches/wmf/1.19wmf1 (modified) (history)
  • /branches/wmf/1.19wmf1/includes (modified) (history)
  • /branches/wmf/1.19wmf1/includes/StreamFile.php (modified) (history)

Diff [purge]

Index: branches/wmf/1.19wmf1/includes/StreamFile.php
@@ -19,18 +19,23 @@
2020 * @return bool Success
2121 */
2222 public static function stream( $fname, $headers = array(), $sendErrors = true ) {
 23+ wfProfileIn( __METHOD__ );
 24+
2325 wfSuppressWarnings();
2426 $stat = stat( $fname );
2527 wfRestoreWarnings();
2628
2729 $res = self::prepareForStream( $fname, $stat, $headers, $sendErrors );
2830 if ( $res == self::NOT_MODIFIED ) {
29 - return true; // use client cache
 31+ $ok = true; // use client cache
3032 } elseif ( $res == self::READY_STREAM ) {
31 - return readfile( $fname );
 33+ $ok = readfile( $fname );
3234 } else {
33 - return false; // failed
 35+ $ok = false; // failed
3436 }
 37+
 38+ wfProfileOut( __METHOD__ );
 39+ return $ok;
3540 }
3641
3742 /**
Property changes on: branches/wmf/1.19wmf1/includes
___________________________________________________________________
Modified: svn:mergeinfo
3843 Merged /trunk/phase3/includes:r112259,112378
Property changes on: branches/wmf/1.19wmf1
___________________________________________________________________
Modified: svn:mergeinfo
3944 Merged /trunk/phase3:r112259,112378

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r112378Added some StreamFile profilingaaron00:53, 25 February 2012

Status & tagging log