From: Tim Starling Date: Fri, 4 Sep 2009 03:41:25 +0000 (+0000) Subject: Fix disabling of APC cache when loading message files: apc.enabled has been PHP_INI_S... X-Git-Tag: 1.31.0-rc.0~39942 X-Git-Url: http://git.cyclocoop.org/%40spipnet%40?a=commitdiff_plain;h=d26d659ef1b1897ad501ed173bca431ecbeab88a;p=lhc%2Fweb%2Fwiklou.git Fix disabling of APC cache when loading message files: apc.enabled has been PHP_INI_SYSTEM since 3.0.13 but apc.cache_by_default works. This reduces the required APC cache space by about half on my test wiki, from 20MB to 10MB. --- diff --git a/includes/LocalisationCache.php b/includes/LocalisationCache.php index d50e1a7c1d..ae9007fb37 100644 --- a/includes/LocalisationCache.php +++ b/includes/LocalisationCache.php @@ -377,9 +377,9 @@ class LocalisationCache { */ protected function readPHPFile( $_fileName, $_fileType ) { // Disable APC caching - $_apcEnabled = ini_set( 'apc.enabled', '0' ); + $_apcEnabled = ini_set( 'apc.cache_by_default', '0' ); include( $_fileName ); - ini_set( 'apc.enabled', $_apcEnabled ); + ini_set( 'apc.cache_by_default', $_apcEnabled ); if ( $_fileType == 'core' || $_fileType == 'extension' ) { $data = compact( self::$allKeys );