Ini_set() #param 2 must be string (php < 8.1)

This commit is contained in:
Sukhwinder Dhillon 2024-01-18 12:25:54 +01:00 committed by Johannes Meyer
parent 2acfdecb8d
commit 3fc16910f7
5 changed files with 7 additions and 7 deletions

View File

@ -82,9 +82,9 @@ class Command extends CliCommand
{
MemoryLimit::raiseTo('1024M');
ini_set('max_execution_time', 0);
ini_set('max_execution_time', '0');
if (version_compare(PHP_VERSION, '7.0.0') < 0) {
ini_set('zend.enable_gc', 0);
ini_set('zend.enable_gc', '0');
}
return $this;

View File

@ -90,7 +90,7 @@ class Migrations
public function applyPendingMigrations()
{
// Ensure we have enough time to migrate
ini_set('max_execution_time', 0);
ini_set('max_execution_time', '0');
foreach ($this->getPendingMigrations() as $migration) {
$migration->apply($this->connection);

View File

@ -448,9 +448,9 @@ class IcingaConfig
$start = microtime(true);
MemoryLimit::raiseTo('1024M');
ini_set('max_execution_time', 0);
ini_set('max_execution_time', '0');
// Workaround for https://bugs.php.net/bug.php?id=68606 or similar
ini_set('zend.enable_gc', 0);
ini_set('zend.enable_gc', '0');
if (! $this->connection->isPgsql() && $this->db->quote("1\0") !== '\'1\\0\'') {
throw new RuntimeException(

View File

@ -154,7 +154,7 @@ class Sync
protected function raiseLimits()
{
MemoryLimit::raiseTo('1024M');
ini_set('max_execution_time', 0);
ini_set('max_execution_time', '0');
return $this;
}

View File

@ -479,7 +479,7 @@ class ImportSource extends DbObjectWithSettings implements ExportInterface
protected function raiseLimits()
{
MemoryLimit::raiseTo('1024M');
ini_set('max_execution_time', 0);
ini_set('max_execution_time', '0');
return $this;
}