https://www.mediawiki.org/wiki/Special:Code/MediaWiki/108331

Revision: 108331
Author:   platonides
Date:     2012-01-07 22:42:05 +0000 (Sat, 07 Jan 2012)
Log Message:
-----------
r102411 fixup. Close register globals vuln, and document 
why is there that require_once.

Modified Paths:
--------------
    trunk/phase3/tests/phpunit/includes/specials/QueryAllSpecialPagesTest.php

Modified: 
trunk/phase3/tests/phpunit/includes/specials/QueryAllSpecialPagesTest.php
===================================================================
--- trunk/phase3/tests/phpunit/includes/specials/QueryAllSpecialPagesTest.php   
2012-01-07 21:59:08 UTC (rev 108330)
+++ trunk/phase3/tests/phpunit/includes/specials/QueryAllSpecialPagesTest.php   
2012-01-07 22:42:05 UTC (rev 108331)
@@ -7,8 +7,14 @@
  * @author Antoine Musso
  * @group Database
  */
+
+if ( !defined( 'MEDIAWIKI' ) ) {
+       die( 1 );
+}
+
 global $IP;
-require_once("$IP/includes/QueryPage.php");
+require_once "$IP/includes/QueryPage.php"; // Needed to populate $wgQueryPages
+
 class QueryAllSpecialPagesTest extends MediaWikiTestCase {
 
        /** List query pages that can not be tested automatically */


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

Reply via email to