Skip to content

Fix use-after-move of ContextContainer in PointerEventsProcessorTest - #57812

Open
javache wants to merge 1 commit into
react:mainfrom
javache:export-D114730311
Open

Fix use-after-move of ContextContainer in PointerEventsProcessorTest#57812
javache wants to merge 1 commit into
react:mainfrom
javache:export-D114730311

Conversation

@javache

@javache javache commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Summary:
The whole PointerEventsProcessorTest suite has been aborting in its fixture constructor since the modernize-use-designated-initializers codemod moved the ContextContainer into ComponentDescriptorParameters. The shared_ptr is read twice more afterwards — once to construct the UIManager and once to construct the ShadowTree — so the move left both with a null container and the second read tripped the libstdc++ null-deref assert.

Stop moving out of a shared_ptr that is still needed by later statements.

Changelog: [Internal]

Differential Revision: D114730311

Summary:
The whole `PointerEventsProcessorTest` suite has been aborting in its fixture constructor since the `modernize-use-designated-initializers` codemod moved the `ContextContainer` into `ComponentDescriptorParameters`. The `shared_ptr` is read twice more afterwards — once to construct the `UIManager` and once to construct the `ShadowTree` — so the move left both with a null container and the second read tripped the libstdc++ null-deref assert.

Stop moving out of a `shared_ptr` that is still needed by later statements.

Changelog: [Internal]

Differential Revision: D114730311
@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Aug 4, 2026
@facebook-github-tools facebook-github-tools Bot added p: Facebook Partner: Facebook Partner labels Aug 4, 2026
@meta-codesync

meta-codesync Bot commented Aug 4, 2026

Copy link
Copy Markdown

@javache has exported this pull request. If you are a Meta employee, you can view the originating Diff in D114730311.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. meta-exported p: Facebook Partner: Facebook Partner

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant