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: screen.getCursorScreenPoint() crash on Wayland #35503

Merged
merged 1 commit into from Sep 5, 2022

Conversation

codebytere
Copy link
Member

Description of Change

Closes #35471.

Fixes an issue where screen.getCursorScreenPoint() crashed on Wayland when it was called before a BrowserWindow had been created. This happened becuase the Wayland implementation requires it. To fix this, we throw an error if a user attempts to call it before creating a BrowserWindow.

Checklist

Release Notes

Notes: Fixed an issue where screen.getCursorScreenPoint() crashed on Wayland when it was called before a BrowserWindow had been created.

@codebytere codebytere added semver/patch backwards-compatible bug fixes target/20-x-y target/21-x-y PR should also be added to the "21-x-y" branch. labels Aug 30, 2022
@electron-cation electron-cation bot added the new-pr 🌱 PR opened in the last 24 hours label Aug 30, 2022
shell/browser/api/electron_api_screen.cc Outdated Show resolved Hide resolved
shell/browser/api/electron_api_screen.cc Outdated Show resolved Hide resolved
@codebytere codebytere force-pushed the fix-wayland-crash branch 2 times, most recently from 01f4fcc to faa7432 Compare August 30, 2022 17:08
@codebytere codebytere requested a review from ckerr August 31, 2022 08:08
@electron-cation electron-cation bot removed the new-pr 🌱 PR opened in the last 24 hours label Aug 31, 2022
@codebytere codebytere merged commit 2db0f7f into main Sep 5, 2022
@codebytere codebytere deleted the fix-wayland-crash branch September 5, 2022 08:10
@release-clerk
Copy link

release-clerk bot commented Sep 5, 2022

Release Notes Persisted

Fixed an issue where screen.getCursorScreenPoint() crashed on Wayland when it was called before a BrowserWindow had been created.

@trop
Copy link
Contributor

trop bot commented Sep 5, 2022

I was unable to backport this PR to "20-x-y" cleanly;
you will need to perform this backport manually.

@trop
Copy link
Contributor

trop bot commented Sep 5, 2022

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

@trop trop bot added in-flight/21-x-y merged/21-x-y PR was merged to the "21-x-y" branch. and removed target/21-x-y PR should also be added to the "21-x-y" branch. in-flight/21-x-y labels Sep 5, 2022
khalwa pushed a commit to solarwindscloud/electron that referenced this pull request Feb 22, 2023
fix: screen.getCursorScreenPoint() crash on Wayland
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged/21-x-y PR was merged to the "21-x-y" branch. semver/patch backwards-compatible bug fixes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: Segfault when calling screen.getCursorScreenPoint() under Wayland
4 participants