Last modified: 2010-05-15 15:41:15 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 7312 - open function tries to send query even if there is no connection
open function tries to send query even if there is no connection
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Database (Other open bugs)
1.7.x
PC All
: Normal trivial (vote)
: ---
Assigned To: Nobody - You can work on this!
: patch
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-09-13 14:20 UTC by Kako
Modified: 2010-05-15 15:41 UTC (History)
0 users

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


Attachments

Description Kako 2006-09-13 14:20:48 UTC
the function tries to make a connection and check if this was successfull. If
not, it reports an error using "wfDebug".
So far ok.
Problem: even if connection wasn't successfull it will triy to send "SET NAMES
utf8" to the server, which throws an exception.

Solution: only send if connection successfull, in other case it makes no sens...

if ( !$success ) {
  $this->reportConnectionError();
} else {
  global $wgDBmysql5;
  if( $wgDBmysql5 ) {
    // Tell the server we're communicating with it in UTF-8.
    // This may engage various charset conversions.
    $this->query( 'SET NAMES utf8' );
  }
}

Result: Installation successfull!
Comment 1 Brion Vibber 2006-09-13 15:27:26 UTC
Fixed on trunk in r16503.

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


Navigation
Links