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
fa0f5bd0
Commit
fa0f5bd0
authored
Jun 28, 2007
by
Juan Lang
Committed by
Alexandre Julliard
Jun 29, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
crypt32: Stub CryptMsgOpenToEncode for data messages.
parent
e8298339
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
27 additions
and
3 deletions
+27
-3
msg.c
dlls/crypt32/msg.c
+27
-0
msg.c
dlls/crypt32/tests/msg.c
+0
-3
No files found.
dlls/crypt32/msg.c
View file @
fa0f5bd0
...
...
@@ -42,6 +42,30 @@ static inline void CryptMsgBase_Init(CryptMsgBase *msg, DWORD dwFlags)
msg
->
open_flags
=
dwFlags
;
}
typedef
struct
_CDataEncodeMsg
{
CryptMsgBase
base
;
}
CDataEncodeMsg
;
static
HCRYPTMSG
CDataEncodeMsg_Open
(
DWORD
dwFlags
,
const
void
*
pvMsgEncodeInfo
,
LPSTR
pszInnerContentObjID
,
PCMSG_STREAM_INFO
pStreamInfo
)
{
CDataEncodeMsg
*
msg
;
if
(
pvMsgEncodeInfo
)
{
SetLastError
(
E_INVALIDARG
);
return
NULL
;
}
FIXME
(
"semi-stub
\n
"
);
msg
=
CryptMemAlloc
(
sizeof
(
CDataEncodeMsg
));
if
(
msg
)
{
CryptMsgBase_Init
((
CryptMsgBase
*
)
msg
,
dwFlags
);
}
return
(
HCRYPTMSG
)
msg
;
}
static
inline
const
char
*
MSG_TYPE_STR
(
DWORD
type
)
{
switch
(
type
)
...
...
@@ -76,6 +100,9 @@ HCRYPTMSG WINAPI CryptMsgOpenToEncode(DWORD dwMsgEncodingType, DWORD dwFlags,
switch
(
dwMsgType
)
{
case
CMSG_DATA
:
msg
=
CDataEncodeMsg_Open
(
dwFlags
,
pvMsgEncodeInfo
,
pszInnerContentObjID
,
pStreamInfo
);
break
;
case
CMSG_SIGNED
:
case
CMSG_ENVELOPED
:
case
CMSG_HASHED
:
...
...
dlls/crypt32/tests/msg.c
View file @
fa0f5bd0
...
...
@@ -275,7 +275,6 @@ static void test_msg_close(void)
ret
=
CryptMsgClose
((
HCRYPTMSG
)
1
);
msg
=
CryptMsgOpenToEncode
(
PKCS_7_ASN_ENCODING
,
0
,
CMSG_DATA
,
NULL
,
NULL
,
NULL
);
todo_wine
ok
(
msg
!=
NULL
,
"CryptMsgOpenToEncode failed: %x
\n
"
,
GetLastError
());
ret
=
CryptMsgClose
(
msg
);
ok
(
ret
,
"CryptMsgClose failed: %x
\n
"
,
GetLastError
());
...
...
@@ -290,13 +289,11 @@ static void test_data_msg_open(void)
SetLastError
(
0xdeadbeef
);
msg
=
CryptMsgOpenToEncode
(
PKCS_7_ASN_ENCODING
,
0
,
CMSG_DATA
,
&
hashInfo
,
NULL
,
NULL
);
todo_wine
{
ok
(
!
msg
&&
GetLastError
()
==
E_INVALIDARG
,
"Expected E_INVALIDARG, got %x
\n
"
,
GetLastError
());
msg
=
CryptMsgOpenToEncode
(
PKCS_7_ASN_ENCODING
,
0
,
CMSG_DATA
,
NULL
,
NULL
,
NULL
);
ok
(
msg
!=
NULL
,
"CryptMsgOpenToEncode failed: %x
\n
"
,
GetLastError
());
}
CryptMsgClose
(
msg
);
}
...
...
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