-
Notifications
You must be signed in to change notification settings - Fork 16.5k
fix: addChildView() crashes when adding a closed WebContentsView #47099
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
💖 Thanks for opening this pull request! 💖 Semantic PR titlesWe use semantic commit messages to streamline the release process. Before your pull request can be merged, you should update your pull request title to start with a semantic prefix. Examples of commit messages with semantic prefixes:
Commit signingThis repo enforces commit signatures for all incoming PRs. PR tipsThings that will help get your PR across the finish line:
We get a lot of pull requests on this repo, so please be patient and we will get back to you as soon as we can. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A similar check should be added in View::RemoveChildView
and moved up from https://github.com/electron/electron/pull/47099/files#diff-ffd5b94a3537909d007f9eee80f2d4b97d56129965fed44226f50c4aad6e5773R278
Also, this should have a test added.
@StaZhu we're prioritizing this as a blocker so if you're able to address these changes please do so or this PR might be superseded by another. |
Sorry, I was OOO last week, I will address the issue this monday🙏. |
3fa706b
to
2e21e37
Compare
We don't need to do this, the current code won't crash if passing a destroyed child view to What's more, there is another test here that verify the function not throw error if view is destroyed. |
2e21e37
to
63a9f7c
Compare
Linting issue fixed, @codebytere could you help re-trigger the CI? |
Looks like CI is green but the commits aren't signed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The commit needs to be signed, but otherwise LGTM
@ckerr Anything wrong with my side? what I can do? Thanks! |
You need to sign your commit - https://docs.github.com/en/authentication/managing-commit-signature-verification/signing-commits |
63a9f7c
to
0a7f5f9
Compare
Done. |
@StaZhu rebasing should fix the error |
2489e2f
to
84704de
Compare
Done. |
Congrats on merging your first pull request! 🎉🎉🎉 |
Release Notes Persisted
|
I have automatically backported this PR to "37-x-y", please check out #47338 |
I have automatically backported this PR to "35-x-y", please check out #47339 |
I have automatically backported this PR to "36-x-y", please check out #47340 |
…ctron#47099) fix: addChildView() crashes when add a closed WebContentsView
Description of Change
Closes #47074
Checklist
npm test
passesRelease Notes
Notes: Fixed
addChildView()
crashes when adding a closed WebContentsView