1
0
mirror of https://github.com/php/php-src.git synced 2026-04-26 01:18:19 +02:00

Merge branch 'PHP-7.4' into PHP-8.0

* PHP-7.4:
  Fix bug #80728: Don't reset the timeout on ini deactivate
This commit is contained in:
Nikita Popov
2021-06-29 16:37:09 +02:00
2 changed files with 13 additions and 3 deletions
+4 -2
View File
@@ -7,8 +7,10 @@ PHP NEWS
(cmb, Nikita)
. Fixed bug #81163 (incorrect handling of indirect vars in __sleep).
(krakjoe)
. Fixed bug #81159 (Object to int warning when using an object as a string offset).
(girgias)
. Fixed bug #81159 (Object to int warning when using an object as a string
offset). (girgias)
. Fixed bug #80728 (PHP built-in web server resets timeout when it can kill
the process). (Calvin Buckley)
- Intl:
. Fixed bug #72809 (Locale::lookup() wrong result with canonicalize option).
+9 -1
View File
@@ -406,7 +406,15 @@ static PHP_INI_MH(OnUpdateTimeout)
}
zend_unset_timeout();
ZEND_ATOL(EG(timeout_seconds), ZSTR_VAL(new_value));
zend_set_timeout(EG(timeout_seconds), 0);
if (stage != PHP_INI_STAGE_DEACTIVATE) {
/*
* If we're restoring INI values, we shouldn't reset the timer.
* Otherwise, the timer is active when PHP is idle, such as the
* the CLI web server or CGI. Running a script will re-activate
* the timeout, so it's not needed to do so at script end.
*/
zend_set_timeout(EG(timeout_seconds), 0);
}
return SUCCESS;
}
/* }}} */