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
da5112c7
Commit
da5112c7
authored
May 22, 2018
by
Matej Špindler
Committed by
Alexandre Julliard
May 22, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32: Check for LOCALE_NOUSEROVERRIDE for neutral locales.
Signed-off-by:
Matej Špindler
<
spindler.matej@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
cd5570d9
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
1 deletion
+5
-1
locale.c
dlls/kernel32/locale.c
+1
-1
locale.c
dlls/kernel32/tests/locale.c
+4
-0
No files found.
dlls/kernel32/locale.c
View file @
da5112c7
...
@@ -1812,7 +1812,7 @@ INT WINAPI GetLocaleInfoEx(LPCWSTR locale, LCTYPE info, LPWSTR buffer, INT len)
...
@@ -1812,7 +1812,7 @@ INT WINAPI GetLocaleInfoEx(LPCWSTR locale, LCTYPE info, LPWSTR buffer, INT len)
/* special handling for neutral locale names */
/* special handling for neutral locale names */
if
(
locale
&&
strlenW
(
locale
)
==
2
)
if
(
locale
&&
strlenW
(
locale
)
==
2
)
{
{
switch
(
info
)
switch
(
info
&
~
LOCALE_LOCALEINFOFLAGSMASK
)
{
{
case
LOCALE_SNAME
:
case
LOCALE_SNAME
:
if
(
len
&&
len
<
3
)
if
(
len
&&
len
<
3
)
...
...
dlls/kernel32/tests/locale.c
View file @
da5112c7
...
@@ -4499,6 +4499,10 @@ static void test_GetLocaleInfoEx(void)
...
@@ -4499,6 +4499,10 @@ static void test_GetLocaleInfoEx(void)
ok
(
ret
==
1
,
"got %d
\n
"
,
ret
);
ok
(
ret
==
1
,
"got %d
\n
"
,
ret
);
ok
(
!
bufferW
[
0
],
"got %s
\n
"
,
wine_dbgstr_w
(
bufferW
));
ok
(
!
bufferW
[
0
],
"got %s
\n
"
,
wine_dbgstr_w
(
bufferW
));
ret
=
pGetLocaleInfoEx
(
enW
,
LOCALE_SPARENT
|
LOCALE_NOUSEROVERRIDE
,
bufferW
,
sizeof
(
bufferW
)
/
sizeof
(
WCHAR
));
ok
(
ret
==
1
,
"got %d
\n
"
,
ret
);
ok
(
!
bufferW
[
0
],
"got %s
\n
"
,
wine_dbgstr_w
(
bufferW
));
ret
=
pGetLocaleInfoEx
(
enW
,
LOCALE_SCOUNTRY
,
bufferW
,
sizeof
(
bufferW
)
/
sizeof
(
WCHAR
));
ret
=
pGetLocaleInfoEx
(
enW
,
LOCALE_SCOUNTRY
,
bufferW
,
sizeof
(
bufferW
)
/
sizeof
(
WCHAR
));
ok
(
ret
==
lstrlenW
(
bufferW
)
+
1
,
"got %d
\n
"
,
ret
);
ok
(
ret
==
lstrlenW
(
bufferW
)
+
1
,
"got %d
\n
"
,
ret
);
if
((
PRIMARYLANGID
(
LANGIDFROMLCID
(
GetSystemDefaultLCID
()))
!=
LANG_ENGLISH
)
||
if
((
PRIMARYLANGID
(
LANGIDFROMLCID
(
GetSystemDefaultLCID
()))
!=
LANG_ENGLISH
)
||
...
...
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