Skip to content

[pull] master from php:master#597

Merged
pull[bot] merged 1 commit into
dolfly:masterfrom
php:master
Mar 8, 2026
Merged

[pull] master from php:master#597
pull[bot] merged 1 commit into
dolfly:masterfrom
php:master

Conversation

@pull

@pull pull Bot commented Mar 8, 2026

Copy link
Copy Markdown

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

…21366)

ReflectionMethod::invoke() (and invokeArgs()) for Closure::__invoke()
incorrectly accepted any Closure object, not just the one the
ReflectionMethod was created from. This happened because all Closures
share a single zend_ce_closure class entry, so the instanceof_function()
check always passed.

Fix: store the original Closure object in intern->obj during
ReflectionMethod construction, then compare object identity in
reflection_method_invoke() to reject different Closure instances.

Closes GH-21362
@pull pull Bot locked and limited conversation to collaborators Mar 8, 2026
@pull pull Bot added the ⤵️ pull label Mar 8, 2026
@pull pull Bot merged commit 53e31d5 into dolfly:master Mar 8, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant