Last modified: 2014-03-11 17:07:02 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T42166, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 40166 - Fatal error: Call to a member function bind() on a non-object in UploadBase.php
Fatal error: Call to a member function bind() on a non-object in UploadBase.php
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
File management (Other open bugs)
unspecified
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks: code_quality
  Show dependency treegraph
 
Reported: 2012-09-11 17:53 UTC by Sam Reed (reedy)
Modified: 2014-03-11 17:07 UTC (History)
6 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Sam Reed (reedy) 2012-09-11 17:53:13 UTC
Fatal error:  Call to a member function bind() on a non-object in /usr/local/apache/common-local/php-1.20wmf11/includes/upload/UploadBase.php on line 247


UploadBase:
$tmpFile = $repo->getLocalCopy( $srcPath );
$tmpFile->bind( $this ); // keep alive with $thumb


File Repo:
	 * @return TempFSFile|null Returns null on failure
	 */
	public function getLocalCopy( $virtualUrl ) {
		$path = $this->resolveToStoragePath( $virtualUrl );
		return $this->backend->getLocalCopy( array( 'src' => $path ) );
	}

FileBackend
	 * @return TempFSFile|null Returns null on failure
	 */
	abstract public function getLocalCopy( array $params );



Something should be checking for null in UploadBase ;)
Comment 1 Krinkle 2012-09-11 17:55:20 UTC
(adding more PHP-characteristics to the title, looked a bit javascripty)
Comment 2 Sam Reed (reedy) 2012-10-23 23:31:05 UTC
[23-Oct-2012 15:14:20] Fatal error: Call to a member function bind() on a non-object at /usr/local/apache/common-local/php-1.21wmf2/includes/upload/UploadBase.php on line 247
Server: srv295
Method: POST
URL: http://commons.wikimedia.org/w/api.php
Backtrace:
#0 /usr/local/apache/common-local/php-1.21wmf2/includes/upload/UploadBase.php(247): UploadBase::getRealPath()
#1 /usr/local/apache/common-local/php-1.21wmf2/includes/upload/UploadFromStash.php(101): UploadBase->getRealPath('mwrepo://local/...')
#2 /usr/local/apache/common-local/php-1.21wmf2/includes/api/ApiUpload.php(336): UploadFromStash->initialize('10y94n6ae130.qe...', 'Himbas.2.JPG')
#3 /usr/local/apache/common-local/php-1.21wmf2/includes/api/ApiUpload.php(64): ApiUpload->selectUploadModule()
#4 /usr/local/apache/common-local/php-1.21wmf2/includes/api/ApiMain.php(820): ApiUpload->execute()
#5 /usr/local/apache/common-local/php-1.21wmf2/includes/api/ApiMain.php(372): ApiMain->executeAction()
#6 /usr/local/apache/common-local/php-1.21wmf2/includes/api/ApiMain.php(349): ApiMain->executeActionWithErrorHandling()
#7 /usr/local/apache/common-local/php-1.21wmf2/api.php(77): ApiMain->execute()
#8 /usr/local/apache/common-local/live-1.5/api.php(3): require('/usr/local/apac...')
#9 {main}
Comment 3 Sam Reed (reedy) 2013-04-03 18:08:48 UTC
Now 257
Comment 4 Sam Reed (reedy) 2013-09-11 23:22:31 UTC
262
Comment 6 Sam Reed (reedy) 2013-11-04 23:58:59 UTC
[04-Nov-2013 23:57:27] Fatal error: Call to a member function bind() on a non-object at /usr/local/apache/common-local/php-1.23wmf2/includes/upload/UploadBase.php on line 262
Server: mw1208
Method: POST
URL: http://commons.wikimedia.org/w/api.php
Backtrace:
#0 /usr/local/apache/common-local/php-1.23wmf2/includes/upload/UploadBase.php(262): UploadBase::getRealPath()
#1 /usr/local/apache/common-local/php-1.23wmf2/includes/upload/UploadFromStash.php(101): UploadBase->getRealPath('mwrepo://local/...')
#2 /usr/local/apache/common-local/php-1.23wmf2/includes/api/ApiUpload.php(396): UploadFromStash->initialize('11uctuuhtfl0.o9...', '003_Acatl??n_de...', true)
#3 /usr/local/apache/common-local/php-1.23wmf2/includes/api/ApiUpload.php(65): ApiUpload->selectUploadModule()
#4 /usr/local/apache/common-local/php-1.23wmf2/includes/api/ApiMain.php(829): ApiUpload->execute()
#5 /usr/local/apache/common-local/php-1.23wmf2/includes/api/ApiMain.php(380): ApiMain->executeAction()
#6 /usr/local/apache/common-local/php-1.23wmf2/includes/api/ApiMain.php(351): ApiMain->executeActionWithErrorHandling()
#7 /usr/local/apache/common-local/php-1.23wmf2/api.php(73): ApiMain->execute()
#8 /usr/local/apache/common-local/w/api.php(3): require('/usr/local/apac...')
#9 {main}
Comment 7 Gerrit Notification Bot 2013-11-20 21:38:39 UTC
Change 96640 had a related patch set uploaded by Aaron Schulz:
Fixed fatal error when getLocalCopy() fails

https://gerrit.wikimedia.org/r/96640
Comment 8 Gerrit Notification Bot 2013-12-02 03:24:26 UTC
Change 96640 merged by jenkins-bot:
Fixed fatal error when getLocalCopy() fails

https://gerrit.wikimedia.org/r/96640
Comment 9 db [inactive,noenotif] 2014-01-11 20:28:36 UTC
Status Merged
Comment 10 Gerrit Notification Bot 2014-01-12 16:02:02 UTC
Change 107040 had a related patch set uploaded by MarkAHershberger:
Fixed fatal error when getLocalCopy() fails

https://gerrit.wikimedia.org/r/107040
Comment 11 Gerrit Notification Bot 2014-01-13 23:24:39 UTC
Change 107040 merged by jenkins-bot:
Fixed fatal error when getLocalCopy() fails

https://gerrit.wikimedia.org/r/107040

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links