mirror of
https://github.com/php/php-src.git
synced 2025-08-19 08:49:28 +02:00
actually copy input to return_value
input is a local var, you can't use it this way
This commit is contained in:
parent
93bb912107
commit
2bbda84c5f
1 changed files with 2 additions and 0 deletions
|
@ -617,10 +617,12 @@ static void php_filter_array_handler(zval *input, zval **op, zval *return_value
|
|||
if (!op) {
|
||||
SEPARATE_ZVAL(&input);
|
||||
*return_value = *input;
|
||||
zval_copy_ctor(return_value);
|
||||
php_filter_call(&return_value, FILTER_DEFAULT, NULL, 0, FILTER_REQUIRE_ARRAY TSRMLS_CC);
|
||||
} else if (Z_TYPE_PP(op) == IS_LONG) {
|
||||
SEPARATE_ZVAL(&input);
|
||||
*return_value = *input;
|
||||
zval_copy_ctor(return_value);
|
||||
php_filter_call(&return_value, Z_LVAL_PP(op), NULL, 0, FILTER_REQUIRE_ARRAY TSRMLS_CC);
|
||||
} else if (Z_TYPE_PP(op) == IS_ARRAY) {
|
||||
array_init(return_value);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue