mirror of
https://github.com/php/php-src.git
synced 2025-01-27 14:13:41 +08:00
fix segfault when retval_ptr is empty - such as when exception thrown
This commit is contained in:
parent
2c6b600a90
commit
bb9ba8e36e
@ -1084,7 +1084,9 @@ static int php_array_walk(HashTable *target_hash, zval **userdata, int recursive
|
||||
|
||||
/* Call the userland function */
|
||||
if (zend_call_function(&fci, &BG(array_walk_fci_cache) TSRMLS_CC) == SUCCESS) {
|
||||
zval_ptr_dtor(&retval_ptr);
|
||||
if (retval_ptr) {
|
||||
zval_ptr_dtor(&retval_ptr);
|
||||
}
|
||||
} else {
|
||||
char *func_name;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user