Fixup some method calls with missing parameters
authorSam Reed <reedy@users.mediawiki.org>
Thu, 2 Sep 2010 21:54:53 +0000 (21:54 +0000)
committerSam Reed <reedy@users.mediawiki.org>
Thu, 2 Sep 2010 21:54:53 +0000 (21:54 +0000)
includes/db/DatabasePostgres.php
includes/specials/SpecialUserlogin.php
maintenance/FiveUpgrade.inc
maintenance/orphans.php

index 88535e7..7a3929b 100644 (file)
@@ -137,7 +137,7 @@ class DatabasePostgres extends DatabaseBase {
 
        function hasConstraint( $name ) {
                global $wgDBmwschema;
-               $SQL = "SELECT 1 FROM pg_catalog.pg_constraint c, pg_catalog.pg_namespace n WHERE c.connamespace = n.oid AND conname = '" . pg_escape_string( $name ) . "' AND n.nspname = '" . pg_escape_string($wgDBmwschema) ."'";
+               $SQL = "SELECT 1 FROM pg_catalog.pg_constraint c, pg_catalog.pg_namespace n WHERE c.connamespace = n.oid AND conname = '" . pg_escape_string( null, $name ) . "' AND n.nspname = '" . pg_escape_string( null, $wgDBmwschema ) ."'";
                return $this->numRows($res = $this->doQuery($SQL));
        }
 
@@ -1339,7 +1339,7 @@ SQL;
        }
 
        function encodeBlob( $b ) {
-               return new Blob ( pg_escape_bytea( $b ) ) ;
+               return new Blob ( pg_escape_bytea( null, $b ) ) ;
        }
 
        function decodeBlob( $b ) {
@@ -1350,7 +1350,7 @@ SQL;
        }
 
        function strencode( $s ) { ## Should not be called by us
-               return pg_escape_string( $s );
+               return pg_escape_string( null, $s );
        }
 
        function addQuotes( $s ) {
@@ -1361,7 +1361,7 @@ SQL;
                } else if ($s instanceof Blob) {
                        return "'".$s->fetch($s)."'";
                }
-               return "'" . pg_escape_string($s) . "'";
+               return "'" . pg_escape_string( null, $s ) . "'";
        }
 
        function quote_ident( $s ) {
index 5e5f6a6..2c90ae1 100644 (file)
@@ -892,7 +892,7 @@ class LoginForm {
        }
 
        /** */
-       function userNotPrivilegedMessage($errors) {
+       function userNotPrivilegedMessage( $errors ) {
                global $wgOut;
 
                $wgOut->setPageTitle( wfMsg( 'permissionserrors' ) );
index fd4bb86..5eebb0e 100644 (file)
@@ -732,7 +732,7 @@ END;
                $info['width'] = $image->getWidth();
                $info['height'] = $image->getHeight();
 
-               $gis = $image->getImageSize();
+               $gis = $image->getImageSize( $filename );
                if ( isset( $gis['bits'] ) ) {
                        $info['bits'] = $gis['bits'];
                }
index a82fa40..df4ba36 100644 (file)
@@ -106,7 +106,7 @@ class Orphans extends Maintenance {
                }
        
                if ( $fix ) {
-                       $dbw->unlockTables();
+                       $dbw->unlockTables( __METHOD__ );
                }
        }
 
@@ -153,7 +153,7 @@ class Orphans extends Maintenance {
                }
        
                if ( $fix ) {
-                       $dbw->unlockTables();
+                       $dbw->unlockTables( __METHOD__ );
                }
        }
 
@@ -226,7 +226,7 @@ class Orphans extends Maintenance {
                }
        
                if ( $fix ) {
-                       $dbw->unlockTables();
+                       $dbw->unlockTables( __METHOD__ );
                }
        }
 }