r110714 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r110713‎ | r110714 | r110715 >
Date:03:52, 5 February 2012
Author:aaron
Status:ok
Tags:filebackend 
Comment:
Removed some useless code and a confusing comment in FSLockManager::doLock(). This was from before referencing counting was used.
Modified paths:
  • /trunk/phase3/includes/filerepo/backend/lockmanager/FSLockManager.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/filerepo/backend/lockmanager/FSLockManager.php
@@ -43,14 +43,9 @@
4444
4545 $lockedPaths = array(); // files locked in this attempt
4646 foreach ( $paths as $path ) {
47 - $subStatus = $this->doSingleLock( $path, $type );
48 - $status->merge( $subStatus );
 47+ $status->merge( $this->doSingleLock( $path, $type ) );
4948 if ( $status->isOK() ) {
50 - // Don't append to $lockedPaths if $path is already locked.
51 - // We do NOT want to unlock the key if we have to rollback.
52 - if ( $subStatus->isGood() ) { // no warnings/fatals?
53 - $lockedPaths[] = $path;
54 - }
 49+ $lockedPaths[] = $path;
5550 } else {
5651 // Abort and unlock everything
5752 $status->merge( $this->doUnlock( $lockedPaths, $type ) );

Status & tagging log