You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
…hin foreach
This happens because getName() resets the iterator to the start because
it overwrites the iterator data.
We add a version of get_first_node that does not overwrite the iterator
data.
* PHP-8.1:
FixGH-12223: Entity reference produces infinite loop in var_dump/print_r
FixGH-12192: SimpleXML infinite loop when getName() is called within foreach
FixGH-12186: segfault copying/cloning a finalized HashContext
* PHP-8.2:
FixGH-12223: Entity reference produces infinite loop in var_dump/print_r
FixGH-12192: SimpleXML infinite loop when getName() is called within foreach
FixGH-12186: segfault copying/cloning a finalized HashContext
* PHP-8.3:
FixGH-12223: Entity reference produces infinite loop in var_dump/print_r
FixGH-12192: SimpleXML infinite loop when getName() is called within foreach
FixGH-12186: segfault copying/cloning a finalized HashContext
Description
The following code:
Resulted in this output:
an infinite loop
But I expected this output instead:
This happens because getName() resets the iterator to the start. It should be fixed by restoring the iterator after fetching the name...
PHP Version
At least 8.1+, probably a very old bug
Operating System
Linux
The text was updated successfully, but these errors were encountered: