X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FForkController.php;h=89ad9553857b4ab2454669b7ecfe069bcd5ea128;hb=510c1d1fd027a90e10d89b249351dec8ab8cb98a;hp=448bc03be717d6d6e12fb788955b8a37ceefaee3;hpb=5f6b22de68f5f107dbe080650caa709d1ff58c6c;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/ForkController.php b/includes/ForkController.php index 448bc03be7..89ad955385 100644 --- a/includes/ForkController.php +++ b/includes/ForkController.php @@ -53,7 +53,7 @@ class ForkController { const RESTART_ON_ERROR = 1; public function __construct( $numProcs, $flags = 0 ) { - if ( php_sapi_name() != 'cli' ) { + if ( PHP_SAPI != 'cli' ) { throw new MWException( "ForkController cannot be used from the web." ); } $this->procsToStart = $numProcs; @@ -140,7 +140,7 @@ class ForkController { // Don't share DB, storage, or memcached connections wfGetLBFactory()->destroyInstance(); FileBackendGroup::destroySingleton(); - LockManagerGroup::destroySingleton(); + LockManagerGroup::destroySingletons(); ObjectCache::clear(); $wgMemc = null; }