mirror of
https://github.com/php/php-src.git
synced 2024-11-24 18:34:21 +08:00
Fixed assignment of reference to itself
This commit is contained in:
parent
753813e542
commit
25bda5ae3c
@ -933,6 +933,9 @@ static inline zval* zend_assign_to_variable(zval *variable_ptr, zval *value TSRM
|
||||
value = Z_REFVAL_P(value);
|
||||
}
|
||||
if (Z_REFCOUNTED_P(value)) {
|
||||
if (UNEXPECTED(variable_ptr == value)) {
|
||||
return variable_ptr;
|
||||
}
|
||||
Z_ADDREF_P(value);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user