History log of /PHP-8.1/Zend/tests/bug80072.phpt (Results 1 – 1 of 1)
Revision Date Author Comments
# 52cf7ab8 02-Jul-2021 Nikita Popov

Fix bug #80072: Root live tmpvars after GC

TMPVAR operands are destroyed using zval_ptr_dtor_nogc(), because
they usually cannot contain cycles. However, there are some rare
exceptio

Fix bug #80072: Root live tmpvars after GC

TMPVAR operands are destroyed using zval_ptr_dtor_nogc(), because
they usually cannot contain cycles. However, there are some rare
exceptions where this is possible, e.g. unserialize() return value.
In such cases we rely on the producing code to root the value. If
a GC run occurs between the rooting and consumption of the value,
we would end up leaking it. To avoid this, root all live TMPVAR
values after a GC run.

Closes GH-7210.

show more ...