Revision: 50168
Author:   tstarling
Date:     2009-05-04 09:31:34 +0000 (Mon, 04 May 2009)

Log Message:
-----------
(bug 18657) Workaround for MySQL optimiser bug. Replaces Domas's live patch.

Modified Paths:
--------------
    trunk/phase3/includes/LogEventsList.php

Modified: trunk/phase3/includes/LogEventsList.php
===================================================================
--- trunk/phase3/includes/LogEventsList.php     2009-05-04 09:29:22 UTC (rev 
50167)
+++ trunk/phase3/includes/LogEventsList.php     2009-05-04 09:31:34 UTC (rev 
50168)
@@ -726,6 +726,17 @@
        public function getTagFilter() {
                return $this->mTagFilter;
        }
+
+       public function doQuery() {
+               // Work around MySQL optimizer bug
+               if ( in_array( get_class( $this->mDb ), array( 'Database', 
'DatabaseMysql' ) ) ) {
+                       $this->mDb->query( 'SET SQL_BIG_SELECTS=1' );
+                       parent::doQuery();
+                       $this->mDb->query( 'SET SQL_BIG_SELECTS=0' );
+               } else {
+                       parent::doQuery();
+               }
+       }
 }
 
 /**



_______________________________________________
MediaWiki-CVS mailing list
MediaWiki-CVS@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to