Skip to content
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

fix: fix cast in ElectronDesktopWindowTreeHostLinux #42179

Merged
merged 1 commit into from
May 14, 2024

Conversation

indutny-signal
Copy link
Contributor

Description of Change

The frame view of the widget is an ClientFrameViewLinux instance only when both frame and client_frame booleans are set to true. Otherwise it is an instance of a different class and thus casting to ClientFrameViewLinux is incorrect and leads to crashes.

Fix: #41839

cc @VerteDinde @ckerr

Checklist

Release Notes

Notes: Fix crash on window maximize on X11

The frame view of the widget is an `ClientFrameViewLinux` instance only
when both `frame` and `client_frame` booleans are set to `true`.
Otherwise it is an instance of a different class and thus casting to
`ClientFrameViewLinux` is incorrect and leads to crashes.

Fix: electron#41839
@electron-cation electron-cation bot added the new-pr 🌱 PR opened in the last 24 hours label May 14, 2024
@VerteDinde VerteDinde added target/30-x-y PR should also be added to the "30-x-y" branch. target/31-x-y PR should also be added to the "31-x-y" branch. semver/patch backwards-compatible bug fixes labels May 14, 2024
Copy link
Member

@VerteDinde VerteDinde left a comment

Choose a reason for hiding this comment

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

Amazing, thank you so much for this fix!

@VerteDinde VerteDinde added the fast-track 🚅 Indicates that this PR is intended to bypass the 24 hour rule. Needs approval from Releases label May 14, 2024
@electron-cation electron-cation bot removed the new-pr 🌱 PR opened in the last 24 hours label May 14, 2024
@VerteDinde VerteDinde changed the title Fix cast in ElectronDesktopWindowTreeHostLinux fix fix cast in ElectronDesktopWindowTreeHostLinux May 14, 2024
@VerteDinde VerteDinde changed the title fix fix cast in ElectronDesktopWindowTreeHostLinux fix: fix cast in ElectronDesktopWindowTreeHostLinux May 14, 2024
@VerteDinde VerteDinde merged commit f2af351 into electron:main May 14, 2024
27 of 28 checks passed
Copy link

release-clerk bot commented May 14, 2024

Release Notes Persisted

Fix crash on window maximize on X11

@trop
Copy link
Contributor

trop bot commented May 14, 2024

I have automatically backported this PR to "31-x-y", please check out #42184

@trop trop bot added in-flight/31-x-y and removed target/31-x-y PR should also be added to the "31-x-y" branch. labels May 14, 2024
@trop
Copy link
Contributor

trop bot commented May 14, 2024

I have automatically backported this PR to "30-x-y", please check out #42185

@trop trop bot added in-flight/30-x-y merged/30-x-y PR was merged to the "30-x-y" branch. and removed target/30-x-y PR should also be added to the "30-x-y" branch. in-flight/30-x-y labels May 14, 2024
@indutny-signal indutny-signal deleted the fix/gh-41839 branch May 15, 2024 00:00
@trop trop bot added merged/31-x-y PR was merged to the "31-x-y" branch. and removed in-flight/31-x-y labels May 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fast-track 🚅 Indicates that this PR is intended to bypass the 24 hour rule. Needs approval from Releases merged/30-x-y PR was merged to the "30-x-y" branch. merged/31-x-y PR was merged to the "31-x-y" branch. semver/patch backwards-compatible bug fixes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: SIGSEGV crash when maximizing window
2 participants