Jjanes has uploaded a new change for review.

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

Change subject: PostgreSQL: Add quotes to timestamp
......................................................................

PostgreSQL: Add quotes to timestamp

The fix for bug T114806 doesn't quote timestamps it sends
directly to the database (i.e. not in bind variables). Timestamps
in PostgreSQL require quotes.  Add addQuotes call.

Bug: T121743
Change-Id: If8da1a0171f55d59c63f5501c854aa8fa48d5992
---
M includes/Import.php
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/36/259636/1

diff --git a/includes/Import.php b/includes/Import.php
index 33ab4ea..b7e91f8 100644
--- a/includes/Import.php
+++ b/includes/Import.php
@@ -1610,7 +1610,7 @@
                $prevId = $dbw->selectField( 'revision', 'rev_id',
                        array(
                                'rev_page' => $pageId,
-                               'rev_timestamp <= ' . $dbw->timestamp( 
$this->timestamp ),
+                               'rev_timestamp <= ' . $dbw->addQuotes( 
$dbw->timestamp( $this->timestamp ) ),
                        ),
                        __METHOD__,
                        array( 'ORDER BY' => array(

-- 
To view, visit https://gerrit.wikimedia.org/r/259636
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: If8da1a0171f55d59c63f5501c854aa8fa48d5992
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Jjanes <[email protected]>

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

Reply via email to