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
2fbe5bea
Commit
2fbe5bea
authored
Feb 23, 2009
by
Paul Vriens
Committed by
Alexandre Julliard
Feb 23, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
crypt32/tests: Prevent a crash on Win9x (test_data_msg).
parent
3c6fb6bb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
12 deletions
+16
-12
msg.c
dlls/crypt32/tests/msg.c
+16
-12
No files found.
dlls/crypt32/tests/msg.c
View file @
2fbe5bea
...
...
@@ -413,18 +413,22 @@ static void test_data_msg_update(void)
ok
(
ret
,
"CryptMsgUpdate failed: %x
\n
"
,
GetLastError
());
CryptMsgClose
(
msg
);
/* Calling update after opening with an empty stream info (with a bogus
* output function) yields an error:
*/
msg
=
CryptMsgOpenToEncode
(
PKCS_7_ASN_ENCODING
,
0
,
CMSG_DATA
,
NULL
,
NULL
,
&
streamInfo
);
SetLastError
(
0xdeadbeef
);
ret
=
CryptMsgUpdate
(
msg
,
msgData
,
sizeof
(
msgData
),
FALSE
);
ok
(
!
ret
&&
(
GetLastError
()
==
STATUS_ACCESS_VIOLATION
||
GetLastError
()
==
STATUS_ILLEGAL_INSTRUCTION
/* WinME */
),
"Expected STATUS_ACCESS_VIOLATION or STATUS_ILLEGAL_INSTRUCTION, got %x
\n
"
,
GetLastError
());
CryptMsgClose
(
msg
);
if
(
have_nt
)
{
/* Calling update after opening with an empty stream info (with a bogus
* output function) yields an error:
*/
/* Crashes on some Win9x */
msg
=
CryptMsgOpenToEncode
(
PKCS_7_ASN_ENCODING
,
0
,
CMSG_DATA
,
NULL
,
NULL
,
&
streamInfo
);
SetLastError
(
0xdeadbeef
);
ret
=
CryptMsgUpdate
(
msg
,
msgData
,
sizeof
(
msgData
),
FALSE
);
ok
(
!
ret
&&
(
GetLastError
()
==
STATUS_ACCESS_VIOLATION
||
GetLastError
()
==
STATUS_ILLEGAL_INSTRUCTION
/* WinME */
),
"Expected STATUS_ACCESS_VIOLATION or STATUS_ILLEGAL_INSTRUCTION, got %x
\n
"
,
GetLastError
());
CryptMsgClose
(
msg
);
}
/* Calling update with a valid output function succeeds, even if the data
* exceeds the size specified in the stream info.
*/
...
...
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