1
0
Fork 0

Check if ini_set exists before calling it

pull/1015/merge
Jordi Boggiano 2012-08-24 16:38:01 +02:00
parent 41fc6ff9ee
commit 573aad8801
2 changed files with 9 additions and 4 deletions

View File

@ -6,8 +6,11 @@ require __DIR__.'/../src/bootstrap.php';
use Composer\Console\Application;
error_reporting(-1);
@ini_set('display_errors', 1);
@ini_set('memory_limit', '512M');
if (function_exists('ini_set')) {
@ini_set('display_errors', 1);
@ini_set('memory_limit', '512M');
}
// run the command application
$application = new Application();

View File

@ -49,8 +49,10 @@ class Application extends BaseApplication
public function __construct()
{
ErrorHandler::register();
ini_set('xdebug.show_exception_trace', false);
ini_set('xdebug.scream', false);
if (function_exists('ini_set')) {
ini_set('xdebug.show_exception_trace', false);
ini_set('xdebug.scream', false);
}
parent::__construct('Composer', Composer::VERSION);
}