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
5d577ae9
Commit
5d577ae9
authored
Mar 05, 2019
by
Brendan McGrath
Committed by
Alexandre Julliard
Mar 05, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
libwine: get_sortkey to return consistent length with and without dstlen.
Signed-off-by:
Brendan McGrath
<
brendan@redmandi.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
7c1e0ef7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
3 deletions
+2
-3
locale.c
dlls/kernel32/tests/locale.c
+0
-1
sortkey.c
libs/wine/sortkey.c
+2
-2
No files found.
dlls/kernel32/tests/locale.c
View file @
5d577ae9
...
...
@@ -2366,7 +2366,6 @@ static void test_LCMapStringA(void)
ret2
=
LCMapStringA
(
LOCALE_USER_DEFAULT
,
LCMAP_SORTKEY
,
upper_case
,
lstrlenA
(
upper_case
),
NULL
,
0
);
ok
(
ret2
,
"LCMapStringA must succeed
\n
"
);
todo_wine
ok
(
ret
==
ret2
,
"lengths of sort keys must be equal (%d vs %d)
\n
"
,
ret
,
ret2
);
/* test LCMAP_SORTKEY | NORM_IGNORECASE */
...
...
libs/wine/sortkey.c
View file @
5d577ae9
...
...
@@ -79,8 +79,8 @@ int wine_get_sortkey(int flags, const WCHAR *src, int srclen, char *dst, int dst
}
if
(
!
dstlen
)
/* compute length */
/* 4 * '\1' +
1 * '\0' +
key length */
return
key_len
[
0
]
+
key_len
[
1
]
+
key_len
[
2
]
+
key_len
[
3
]
+
4
+
1
;
/* 4 * '\1' + key length */
return
key_len
[
0
]
+
key_len
[
1
]
+
key_len
[
2
]
+
key_len
[
3
]
+
4
;
if
(
dstlen
<
key_len
[
0
]
+
key_len
[
1
]
+
key_len
[
2
]
+
key_len
[
3
]
+
4
+
1
)
return
0
;
/* overflow */
...
...
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