mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2: Fix GH-14590: Memory leak in FPM test gh13563-conf-bool-env.phpt
This commit is contained in:
commit
41371900a8
2 changed files with 6 additions and 2 deletions
2
NEWS
2
NEWS
|
@ -6,6 +6,8 @@ PHP NEWS
|
|||
. Fixed bug GH-13922 (Fixed support for systems with
|
||||
sysconf(_SC_GETPW_R_SIZE_MAX) == -1). (Arnaud)
|
||||
. Fixed bug GH-14626 (Fix is_zend_ptr() for huge blocks). (Arnaud)
|
||||
. Fixed bug GH-14590 (Memory leak in FPM test gh13563-conf-bool-env.phpt.
|
||||
(nielsdos)
|
||||
|
||||
- Phar:
|
||||
. Fixed bug GH-14603 (null string from zip entry).
|
||||
|
|
|
@ -179,8 +179,10 @@ static void zend_ini_get_var(zval *result, zval *name, zval *fallback)
|
|||
if ((curval = zend_get_configuration_directive(Z_STR_P(name))) != NULL) {
|
||||
ZVAL_NEW_STR(result, zend_string_init(Z_STRVAL_P(curval), Z_STRLEN_P(curval), ZEND_SYSTEM_INI));
|
||||
/* ..or if not found, try ENV */
|
||||
} else if ((envvar = zend_getenv(Z_STRVAL_P(name), Z_STRLEN_P(name))) != NULL ||
|
||||
(envvar = getenv(Z_STRVAL_P(name))) != NULL) {
|
||||
} else if ((envvar = zend_getenv(Z_STRVAL_P(name), Z_STRLEN_P(name))) != NULL) {
|
||||
ZVAL_NEW_STR(result, zend_string_init(envvar, strlen(envvar), ZEND_SYSTEM_INI));
|
||||
efree(envvar);
|
||||
} else if ((envvar = getenv(Z_STRVAL_P(name))) != NULL) {
|
||||
ZVAL_NEW_STR(result, zend_string_init(envvar, strlen(envvar), ZEND_SYSTEM_INI));
|
||||
/* ..or if not defined, try fallback value */
|
||||
} else if (fallback) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue