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
04a65b3c
Commit
04a65b3c
authored
Oct 08, 2008
by
Juan Lang
Committed by
Alexandre Julliard
Oct 09, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wintrust: Fix test failures on Win9x.
parent
a4ed7a10
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
2 deletions
+11
-2
asn.c
dlls/wintrust/tests/asn.c
+11
-2
No files found.
dlls/wintrust/tests/asn.c
View file @
04a65b3c
...
...
@@ -83,7 +83,9 @@ static void test_encodeSPCLink(void)
SetLastError
(
0xdeadbeef
);
ret
=
pCryptEncodeObjectEx
(
X509_ASN_ENCODING
,
SPC_LINK_STRUCT
,
&
link
,
CRYPT_ENCODE_ALLOC_FLAG
,
NULL
,
&
buf
,
&
size
);
ok
(
!
ret
&&
GetLastError
()
==
CRYPT_E_INVALID_IA5_STRING
,
ok
(
!
ret
&&
(
GetLastError
()
==
CRYPT_E_INVALID_IA5_STRING
||
GetLastError
()
==
OSS_BAD_PTR
/* Win9x */
),
"Expected CRYPT_E_INVALID_IA5_STRING, got %08x
\n
"
,
GetLastError
());
/* Unlike the crypt32 string encoding routines, size is not set to the
* index of the first invalid character.
...
...
@@ -229,7 +231,9 @@ static void test_decodeSPCLink(void)
ret
=
pCryptDecodeObjectEx
(
X509_ASN_ENCODING
,
SPC_LINK_STRUCT
,
badMonikerSPCLink
,
sizeof
(
badMonikerSPCLink
),
CRYPT_DECODE_ALLOC_FLAG
,
NULL
,
(
BYTE
*
)
&
buf
,
&
size
);
ok
(
!
ret
&&
GetLastError
()
==
CRYPT_E_BAD_ENCODE
,
ok
(
!
ret
&&
(
GetLastError
()
==
CRYPT_E_BAD_ENCODE
||
GetLastError
()
==
OSS_DATA_ERROR
/* Win9x */
),
"Expected CRYPT_E_BAD_ENCODE, got %08x
\n
"
,
GetLastError
());
}
...
...
@@ -296,6 +300,11 @@ static void test_encodeSPCPEImage(void)
imageData
.
Flags
.
cbData
=
sizeof
(
flags
);
ret
=
pCryptEncodeObjectEx
(
X509_ASN_ENCODING
,
SPC_PE_IMAGE_DATA_STRUCT
,
&
imageData
,
CRYPT_ENCODE_ALLOC_FLAG
,
NULL
,
&
buf
,
&
size
);
if
(
!
ret
&&
GetLastError
()
==
OSS_TOO_LONG
)
{
skip
(
"SPC_PE_IMAGE_DATA_STRUCT not supported
\n
"
);
return
;
}
ok
(
ret
,
"CryptEncodeObjectEx failed: %08x
\n
"
,
GetLastError
());
if
(
ret
)
{
...
...
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