From: Mark A. Hershberger Date: Tue, 18 Oct 2011 21:09:52 +0000 (+0000) Subject: revert r99562 and set standard_conforming_strings “on” by default X-Git-Tag: 1.31.0-rc.0~27022 X-Git-Url: http://git.cyclocoop.org/%24action?a=commitdiff_plain;h=71d5b68221002d71c88783acab7df267a4e04cec;p=lhc%2Fweb%2Fwiklou.git revert r99562 and set standard_conforming_strings “on” by default --- diff --git a/includes/db/DatabasePostgres.php b/includes/db/DatabasePostgres.php index 1b0539c14b..8974dc8990 100644 --- a/includes/db/DatabasePostgres.php +++ b/includes/db/DatabasePostgres.php @@ -200,6 +200,7 @@ class DatabasePostgres extends DatabaseBase { $this->query( "SET client_encoding='UTF8'", __METHOD__ ); $this->query( "SET datestyle = 'ISO, YMD'", __METHOD__ ); $this->query( "SET timezone = 'GMT'", __METHOD__ ); + $this->query( "SET standard_conforming_strings = on", __METHOD__ ); global $wgDBmwschema; if ( $this->schemaExists( $wgDBmwschema ) ) { @@ -878,11 +879,7 @@ SQL; } elseif ( is_bool( $s ) ) { return intval( $s ); } elseif ( $s instanceof Blob ) { - $ret = "'" . $s->fetch( $s ) . "'"; - if ( $this->numeric_version >= 8.1 ) { - $ret = "E$ret"; - } - return $ret; + return "'" . $s->fetch( $s ) . "'"; } return "'" . pg_escape_string( $this->mConn, $s ) . "'"; }