mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Simplify always-true check in zend_generator_update_current (#13848)
`old_root` is dereferenced at top, so `old_root` must not be NULL, and the check doesn't actually do anything.
This commit is contained in:
parent
30885f3b5f
commit
c3f5bbde2a
1 changed files with 1 additions and 1 deletions
|
@ -579,7 +579,7 @@ ZEND_API zend_generator *zend_generator_update_current(zend_generator *generator
|
||||||
|
|
||||||
EG(current_execute_data) = original_execute_data;
|
EG(current_execute_data) = original_execute_data;
|
||||||
|
|
||||||
if (!((old_root ? old_root : generator)->flags & ZEND_GENERATOR_CURRENTLY_RUNNING)) {
|
if (!(old_root->flags & ZEND_GENERATOR_CURRENTLY_RUNNING)) {
|
||||||
new_root->node.parent = NULL;
|
new_root->node.parent = NULL;
|
||||||
OBJ_RELEASE(&new_root_parent->std);
|
OBJ_RELEASE(&new_root_parent->std);
|
||||||
zend_generator_resume(generator);
|
zend_generator_resume(generator);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue