8000 fix: crash caused by `app.getLocaleCountryCode()` by trop[bot] · Pull Request #32332 · electron/electron · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

fix: crash caused by app.getLocaleCountryCode() #32332

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

trop[bot]
Copy link
Contributor
@trop trop bot commented Jan 4, 2022

Backport of #32256

See that PR for details.

Notes: Fixed a crash caused by app.getLocaleCountryCode().

CFLocaleGetValue() returned null and crashed the process when
app.getLocaleCountryCode() was run on a CircleCI metal resource class
macOS instance with Xcode 12.5.1. This change fixes that logic and adds
further checks to make the code future-proof.

Here too people are complaining that the returned country code migth be
null: https://stackoverflow.com/questions/15202454/nslocalecountrycode-returns-nil

Signed-off-by: Darshan Sen <darshan.sen@postman.com>
@electron-cation electron-cation bot added the new-pr 🌱 PR opened recently label Jan 4, 2022
@trop trop bot added 15-x-y backport This is a backport PR semver/patch backwards-compatible bug fixes labels Jan 4, 2022
@electron-cation electron-cation bot removed the new-pr 🌱 PR opened recently label Jan 4, 2022
@zcbenz zcbenz merged commit 099560c into 15-x-y Jan 5, 2022
@zcbenz zcbenz deleted the trop/15-x-y-bp-fix-crash-caused-by-app-getlocalecountrycode--1641261617823 branch January 5, 2022 09:35
@release-clerk
Copy link
release-clerk bot commented Jan 5, 2022

Release Notes Persisted

Fixed a crash caused by app.getLocaleCountryCode().

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
15-x-y backport This is a backport PR semver/patch backwards-compatible bug fixes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0