installer: Use wfLoadExtension/Skin in LocalSettingsGenerator
[lhc/web/wiklou.git] / includes / Setup.php
index ed0aabe..e281768 100644 (file)
@@ -362,10 +362,15 @@ if ( $wgMetaNamespace === false ) {
        $wgMetaNamespace = str_replace( ' ', '_', $wgSitename );
 }
 
-// Default value is either the suhosin limit or -1 for unlimited
+// Default value is 2000 or the suhosin limit if it is between 1 and 2000
 if ( $wgResourceLoaderMaxQueryLength === false ) {
-       $maxValueLength = ini_get( 'suhosin.get.max_value_length' );
-       $wgResourceLoaderMaxQueryLength = $maxValueLength > 0 ? $maxValueLength : -1;
+       $suhosinMaxValueLength = (int) ini_get( 'suhosin.get.max_value_length' );
+       if ( $suhosinMaxValueLength > 0 && $suhosinMaxValueLength < 2000 ) {
+               $wgResourceLoaderMaxQueryLength = $suhosinMaxValueLength;
+       } else {
+               $wgResourceLoaderMaxQueryLength = 2000;
+       }
+       unset($suhosinMaxValueLength);
 }
 
 /**
@@ -479,7 +484,7 @@ if ( !class_exists( 'AutoLoader' ) ) {
 
 MWExceptionHandler::installHandler();
 
-require_once "$IP/includes/normal/UtfNormalUtil.php";
+require_once "$IP/includes/libs/normal/UtfNormalUtil.php";
 
 $ps_default2 = Profiler::instance()->scopedProfileIn( $fname . '-defaults2' );
 
@@ -573,7 +578,6 @@ $ps_memcached = Profiler::instance()->scopedProfileIn( $fname . '-memcached' );
 $wgMemc = wfGetMainCache();
 $messageMemc = wfGetMessageCacheStorage();
 $parserMemc = wfGetParserCacheStorage();
-$wgLangConvMemc = wfGetLangConverterCacheStorage();
 
 wfDebugLog( 'caches', 'main: ' . get_class( $wgMemc ) .
        ', message: ' . get_class( $messageMemc ) .