http://www.mediawiki.org/wiki/Special:Code/MediaWiki/84485

Revision: 84485
Author:   greg
Date:     2011-03-21 21:20:11 +0000 (Mon, 21 Mar 2011)
Log Message:
-----------
Do not depend on the lack of a server for connecting: Postgres has a valid and 
common use case where the server name (aka host) is empty, as the connection is 
via a Unix socket. Instead, check if a $user has been sent to the function, as 
all databases can agree that we need at least that much before doing an open. 
Fixes bug 28167.

Modified Paths:
--------------
    trunk/phase3/includes/db/Database.php

Modified: trunk/phase3/includes/db/Database.php
===================================================================
--- trunk/phase3/includes/db/Database.php       2011-03-21 20:49:56 UTC (rev 
84484)
+++ trunk/phase3/includes/db/Database.php       2011-03-21 21:20:11 UTC (rev 
84485)
@@ -518,7 +518,7 @@
                        $this->mTablePrefix = $tablePrefix;
                }
 
-               if ( $server ) {
+               if ( $user ) {
                        $this->open( $server, $user, $password, $dbName );
                }
        }


_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to