Skip to content

Fix potential thread safety issue in NetworkProcessProxy::sendCreationParametersToNewProcess #47269

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

charliewolfe
Copy link
Member

@charliewolfe charliewolfe commented Jun 26, 2025

033a234

Fix potential thread safety issue in `NetworkProcessProxy::sendCreationParametersToNewProcess`
https://bugs.webkit.org/show_bug.cgi?id=295075
rdar://154440502

Reviewed by Chris Dumez.

I noticed this while investigating rdar://154344286. If sendCreationParametersToNewProcess is not called
on the main thread and we use callOnMainRunLoopAndWait to ensure it is, then we need to return afterward.

* Source/WebKit/UIProcess/Network/NetworkProcessProxy.cpp:
(WebKit::NetworkProcessProxy::sendCreationParametersToNewProcess):

Canonical link: https://commits.webkit.org/296711@main

114333a

Misc iOS, visionOS, tvOS & watchOS macOS Linux Windows
✅ 🧪 style ✅ 🛠 ios ✅ 🛠 mac ✅ 🛠 wpe ✅ 🛠 win
✅ 🛠 ios-sim ✅ 🛠 mac-AS-debug ✅ 🧪 wpe-wk2 ⏳ 🧪 win-tests
✅ 🧪 webkitperl ✅ 🧪 ios-wk2 ✅ 🧪 api-mac ✅ 🧪 api-wpe
✅ 🧪 ios-wk2-wpt ✅ 🛠 wpe-cairo
✅ 🧪 api-ios ✅ 🧪 mac-wk2 ✅ 🛠 gtk
✅ 🛠 vision ✅ 🧪 mac-AS-debug-wk2 ✅ 🧪 gtk-wk2
✅ 🛠 vision-sim ✅ 🧪 mac-wk2-stress ✅ 🧪 api-gtk
✅ 🧪 vision-wk2 ✅ 🧪 mac-intel-wk2 ✅ 🛠 playstation
✅ 🛠 🧪 unsafe-merge ✅ 🛠 tv ✅ 🛠 mac-safer-cpp
✅ 🛠 tv-sim
✅ 🛠 watch
✅ 🛠 watch-sim

@charliewolfe charliewolfe requested a review from cdumez as a code owner June 26, 2025 23:47
@charliewolfe charliewolfe self-assigned this Jun 26, 2025
@charliewolfe charliewolfe added the WebKit Process Model Bugs related to WebKit's multi-process architecture label Jun 26, 2025
Copy link
Contributor

@cdumez cdumez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oops

@charliewolfe charliewolfe added the unsafe-merge-queue Applied to send a pull request to merge-queue, but skip building and testing label Jun 27, 2025
…onParametersToNewProcess`

https://bugs.webkit.org/show_bug.cgi?id=295075
rdar://154440502

Reviewed by Chris Dumez.

I noticed this while investigating rdar://154344286. If sendCreationParametersToNewProcess is not called
on the main thread and we use callOnMainRunLoopAndWait to ensure it is, then we need to return afterward.

* Source/WebKit/UIProcess/Network/NetworkProcessProxy.cpp:
(WebKit::NetworkProcessProxy::sendCreationParametersToNewProcess):

Canonical link: https://commits.webkit.org/296711@main
@webkit-commit-queue webkit-commit-queue force-pushed the eng/Fix-potential-thread-safety-issue-in-NetworkProcessProxy-sendCreationParametersToNewProcess branch from 114333a to 033a234 Compare June 27, 2025 07:57
@webkit-commit-queue
Copy link
Collaborator

Committed 296711@main (033a234): https://commits.webkit.org/296711@main

Reviewed commits have been landed. Closing PR #47269 and removing active labels.

@webkit-commit-queue webkit-commit-queue merged commit 033a234 into WebKit:main Jun 27, 2025
@webkit-commit-queue webkit-commit-queue removed the unsafe-merge-queue Applied to send a pull request to merge-queue, but skip building and testing label Jun 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
WebKit Process Model Bugs related to WebKit's multi-process architecture
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants