Skip to content

Fix hooked object properties overflow#20988

Closed
iluuu1994 wants to merge 1 commit intophp:PHP-8.4from
iluuu1994:gh-20479
Closed

Fix hooked object properties overflow#20988
iluuu1994 wants to merge 1 commit intophp:PHP-8.4from
iluuu1994:gh-20479

Conversation

@iluuu1994
Copy link
Copy Markdown
Member

@iluuu1994 iluuu1994 commented Jan 21, 2026

The computed number of properties using zend_hash_num_elements(zobj->properties) is incorrect when the object contains virtual properties. We don't have a trivial way to find the number of properties virtual properties that need to be added to this number, so just append with zend_hash_add_new() instead.

Fixes GH-20479

The computed number of properties using zend_hash_num_elements(zobj->properties)
is incorrect when the object contains virtual properties. We don't have a
trivial way to find the number of properties virtual properties that need to be
added to this number, so just append with zend_hash_add_new() instead.

Fixes phpGH-20479
@iluuu1994 iluuu1994 closed this in d9cbc31 Jan 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants