Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
b0935ab8
Commit
b0935ab8
authored
Apr 16, 2014
by
Erich E. Hoover
Committed by
Alexandre Julliard
Apr 17, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32: Allow CompareStringEx NORM_LINGUISTIC_CASING flag.
parent
4b949510
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
7 deletions
+9
-7
locale.c
dlls/kernel32/locale.c
+7
-5
locale.c
dlls/kernel32/tests/locale.c
+2
-2
No files found.
dlls/kernel32/locale.c
View file @
b0935ab8
...
...
@@ -2985,6 +2985,10 @@ INT WINAPI CompareStringW(LCID lcid, DWORD flags,
INT
WINAPI
CompareStringEx
(
LPCWSTR
locale
,
DWORD
flags
,
LPCWSTR
str1
,
INT
len1
,
LPCWSTR
str2
,
INT
len2
,
LPNLSVERSIONINFO
version
,
LPVOID
reserved
,
LPARAM
lParam
)
{
DWORD
supported_flags
=
NORM_IGNORECASE
|
NORM_IGNORENONSPACE
|
NORM_IGNORESYMBOLS
|
SORT_STRINGSORT
|
NORM_IGNOREKANATYPE
|
NORM_IGNOREWIDTH
|
LOCALE_USE_CP_ACP
;
DWORD
semistub_flags
=
NORM_LINGUISTIC_CASING
|
0x10000000
;
/* 0x10000000 is related to diacritics in Arabic, Japanese, and Hebrew */
INT
ret
;
if
(
version
)
FIXME
(
"unexpected version parameter
\n
"
);
...
...
@@ -2997,16 +3001,14 @@ INT WINAPI CompareStringEx(LPCWSTR locale, DWORD flags, LPCWSTR str1, INT len1,
return
0
;
}
if
(
flags
&
~
(
NORM_IGNORECASE
|
NORM_IGNORENONSPACE
|
NORM_IGNORESYMBOLS
|
SORT_STRINGSORT
|
NORM_IGNOREKANATYPE
|
NORM_IGNOREWIDTH
|
LOCALE_USE_CP_ACP
|
0x10000000
)
)
if
(
flags
&
~
(
supported_flags
|
semistub_flags
))
{
SetLastError
(
ERROR_INVALID_FLAGS
);
return
0
;
}
/* this style is related to diacritics in Arabic, Japanese, and Hebrew */
if
(
flags
&
0x10000000
)
WARN
(
"Ignoring unknown flags 0x10000000
\n
"
);
if
(
flags
&
semistub_flags
)
FIXME
(
"semi-stub behavor for flag(s) 0x%x
\n
"
,
flags
&
semistub_flags
);
if
(
len1
<
0
)
len1
=
strlenW
(
str1
);
if
(
len2
<
0
)
len2
=
strlenW
(
str2
);
...
...
dlls/kernel32/tests/locale.c
View file @
b0935ab8
...
...
@@ -1543,7 +1543,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
},
{
/* 13 */
"tr-TR"
,
NORM_LINGUISTIC_CASING
,
{
'i'
,
0
},
{
0x130
,
0
},
CSTR_LESS_THAN
,
-
1
,
TRU
E
{
'i'
,
0
},
{
0x130
,
0
},
CSTR_LESS_THAN
,
-
1
,
FALS
E
},
{
/* 14 */
"tr-TR"
,
NORM_LINGUISTIC_CASING
,
...
...
@@ -1593,7 +1593,7 @@ static const struct comparestringex_test comparestringex_tests[] = {
},
{
/* 25 */
"tr-TR"
,
NORM_LINGUISTIC_CASING
|
NORM_IGNORECASE
,
{
'i'
,
0
},
{
0x130
,
0
},
CSTR_EQUAL
,
CSTR_LESS_THAN
,
TRU
E
{
'i'
,
0
},
{
0x130
,
0
},
CSTR_EQUAL
,
CSTR_LESS_THAN
,
FALS
E
},
{
/* 26 */
"tr-TR"
,
NORM_LINGUISTIC_CASING
|
NORM_IGNORECASE
,
...
...
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