Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
c3062650
Commit
c3062650
authored
Apr 01, 2022
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernelbase: Check the locale name instead of the LCID to detect changes.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
c0ff1a22
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
locale.c
dlls/kernelbase/locale.c
+7
-4
No files found.
dlls/kernelbase/locale.c
View file @
c3062650
...
...
@@ -1543,6 +1543,7 @@ void init_locale( HMODULE module )
void
*
sort_ptr
;
WCHAR
bufferW
[
LOCALE_NAME_MAX_LENGTH
];
DYNAMIC_TIME_ZONE_INFORMATION
timezone
;
const
WCHAR
*
user_locale_name
;
DWORD
count
;
SIZE_T
size
;
HKEY
hkey
;
...
...
@@ -1621,13 +1622,15 @@ void init_locale( HMODULE module )
/* Update registry contents if the user locale has changed.
* This simulates the action of the Windows control panel. */
user_locale_name
=
locale_strings
+
user_locale
->
sname
+
1
;
count
=
sizeof
(
bufferW
);
if
(
!
RegQueryValueExW
(
intl_key
,
L"Locale"
,
NULL
,
NULL
,
(
BYTE
*
)
bufferW
,
&
count
))
if
(
!
RegQueryValueExW
(
intl_key
,
L"Locale
Name
"
,
NULL
,
NULL
,
(
BYTE
*
)
bufferW
,
&
count
))
{
if
(
wcstoul
(
bufferW
,
NULL
,
16
)
==
user_lcid
)
return
;
/* already set correctly */
TRACE
(
"updating registry, locale changed %s -> %08lx
\n
"
,
debugstr_w
(
bufferW
),
user_lcid
);
if
(
!
wcscmp
(
bufferW
,
user_locale_name
))
return
;
/* unchanged */
TRACE
(
"updating registry, locale changed %s -> %s
\n
"
,
debugstr_w
(
bufferW
),
debugstr_w
(
user_locale_name
)
);
}
else
TRACE
(
"updating registry, locale changed none -> %
08lx
\n
"
,
user_lcid
);
else
TRACE
(
"updating registry, locale changed none -> %
s
\n
"
,
debugstr_w
(
user_locale_name
)
);
update_locale_registry
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment