[PATCH 1/2] kernelbase: Autoset GeoID on process launch.
João Diogo Ferreira
devilj at outlook.pt
Sat Nov 23 12:38:36 CST 2019
Wine-bug: https://bugs.winehq.org/show_bug.cgi?id=46196
Signed-off-by: João Diogo Craveiro Ferreira <devilj at outlook.pt>
---
Supersedes: 174002, 173827
---
dlls/kernelbase/locale.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/dlls/kernelbase/locale.c b/dlls/kernelbase/locale.c
index 512c3aeeb1..2e40fc166d 100644
--- a/dlls/kernelbase/locale.c
+++ b/dlls/kernelbase/locale.c
@@ -108,6 +108,7 @@ void init_locale(void)
{
LCID lcid = GetUserDefaultLCID();
WCHAR bufferW[80];
+ GEOID geoid = GEOID_NOT_AVAILABLE;
DWORD count, i;
HKEY hkey;
@@ -147,6 +148,11 @@ void init_locale(void)
(BYTE *)bufferW, (lstrlenW(bufferW) + 1) * sizeof(WCHAR) );
}
+ GetLocaleInfoW( LOCALE_USER_DEFAULT, LOCALE_IGEOID | LOCALE_RETURN_NUMBER,
+ (WCHAR *)&geoid, sizeof(geoid)/sizeof(WCHAR) );
+
+ SetUserGeoID(geoid);
+
if (!RegCreateKeyExW( nls_key, L"Codepage",
0, NULL, REG_OPTION_NON_VOLATILE, KEY_ALL_ACCESS, NULL, &hkey, NULL ))
{
--
2.24.0
More information about the wine-devel
mailing list