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
75236a63
Commit
75236a63
authored
Jun 26, 2018
by
Marcus Meissner
Committed by
Alexandre Julliard
Jun 26, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shlwapi: SHGetIniStringW buffer size is in characters.
Signed-off-by:
Marcus Meissner
<
meissner@suse.de
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
24ffba47
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
ordinal.c
dlls/shlwapi/tests/ordinal.c
+6
-6
No files found.
dlls/shlwapi/tests/ordinal.c
View file @
75236a63
...
...
@@ -2724,8 +2724,8 @@ static void test_SHGetIniString(void)
if
(
0
){
/* these crash on Windows */
pSHGetIniStringW
(
NULL
,
NULL
,
NULL
,
0
,
NULL
);
pSHGetIniStringW
(
NULL
,
AKeyW
,
out
,
sizeof
(
out
),
pathW
);
pSHGetIniStringW
(
TestAppW
,
AKeyW
,
NULL
,
sizeof
(
out
),
pathW
);
pSHGetIniStringW
(
NULL
,
AKeyW
,
out
,
ARRAY_SIZE
(
out
),
pathW
);
pSHGetIniStringW
(
TestAppW
,
AKeyW
,
NULL
,
ARRAY_SIZE
(
out
),
pathW
);
}
ret
=
pSHGetIniStringW
(
TestAppW
,
AKeyW
,
out
,
0
,
pathW
);
...
...
@@ -2734,21 +2734,21 @@ static void test_SHGetIniString(void)
/* valid arguments */
out
[
0
]
=
0
;
SetLastError
(
0xdeadbeef
);
ret
=
pSHGetIniStringW
(
TestAppW
,
NULL
,
out
,
sizeof
(
out
),
pathW
);
ret
=
pSHGetIniStringW
(
TestAppW
,
NULL
,
out
,
ARRAY_SIZE
(
out
),
pathW
);
ok
(
ret
==
4
,
"SHGetIniStringW should have given 4, instead: %d
\n
"
,
ret
);
ok
(
!
lstrcmpW
(
out
,
AKeyW
),
"Expected %s, got: %s, %d
\n
"
,
wine_dbgstr_w
(
AKeyW
),
wine_dbgstr_w
(
out
),
GetLastError
());
ret
=
pSHGetIniStringW
(
TestAppW
,
AKeyW
,
out
,
sizeof
(
out
),
pathW
);
ret
=
pSHGetIniStringW
(
TestAppW
,
AKeyW
,
out
,
ARRAY_SIZE
(
out
),
pathW
);
ok
(
ret
==
1
,
"SHGetIniStringW should have given 1, instead: %d
\n
"
,
ret
);
ok
(
!
strcmp_wa
(
out
,
"1"
),
"Expected L
\"
1
\"
, got: %s
\n
"
,
wine_dbgstr_w
(
out
));
ret
=
pSHGetIniStringW
(
TestAppW
,
AnotherKeyW
,
out
,
sizeof
(
out
),
pathW
);
ret
=
pSHGetIniStringW
(
TestAppW
,
AnotherKeyW
,
out
,
ARRAY_SIZE
(
out
),
pathW
);
ok
(
ret
==
4
,
"SHGetIniStringW should have given 4, instead: %d
\n
"
,
ret
);
ok
(
!
strcmp_wa
(
out
,
"asdf"
),
"Expected L
\"
asdf
\"
, got: %s
\n
"
,
wine_dbgstr_w
(
out
));
out
[
0
]
=
1
;
ret
=
pSHGetIniStringW
(
TestAppW
,
JunkKeyW
,
out
,
sizeof
(
out
),
pathW
);
ret
=
pSHGetIniStringW
(
TestAppW
,
JunkKeyW
,
out
,
ARRAY_SIZE
(
out
),
pathW
);
ok
(
ret
==
0
,
"SHGetIniStringW should have given 0, instead: %d
\n
"
,
ret
);
ok
(
*
out
==
0
,
"Expected L
\"\"
, got: %s
\n
"
,
wine_dbgstr_w
(
out
));
...
...
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