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
70c4b667
Commit
70c4b667
authored
Feb 13, 2008
by
Andrew Talbot
Committed by
Alexandre Julliard
Feb 15, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
crypt32: Assign to structs instead of using memcpy.
parent
649d8b52
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
9 deletions
+7
-9
chain.c
dlls/crypt32/chain.c
+2
-4
msg.c
dlls/crypt32/msg.c
+2
-2
sip.c
dlls/crypt32/sip.c
+3
-3
No files found.
dlls/crypt32/chain.c
View file @
70c4b667
...
...
@@ -986,8 +986,7 @@ static BOOL CRYPT_BuildCandidateChainFromCert(HCERTCHAINENGINE hChainEngine,
chain
->
ref
=
1
;
chain
->
world
=
world
;
chain
->
context
.
cbSize
=
sizeof
(
CERT_CHAIN_CONTEXT
);
memcpy
(
&
chain
->
context
.
TrustStatus
,
&
simpleChain
->
TrustStatus
,
sizeof
(
CERT_TRUST_STATUS
));
chain
->
context
.
TrustStatus
=
simpleChain
->
TrustStatus
;
chain
->
context
.
cChain
=
1
;
chain
->
context
.
rgpChain
=
CryptMemAlloc
(
sizeof
(
PCERT_SIMPLE_CHAIN
));
chain
->
context
.
rgpChain
[
0
]
=
simpleChain
;
...
...
@@ -1029,8 +1028,7 @@ static PCERT_SIMPLE_CHAIN CRYPT_CopySimpleChainToElement(
if
(
element
)
{
memcpy
(
element
,
chain
->
rgpElement
[
i
],
sizeof
(
CERT_CHAIN_ELEMENT
));
*
element
=
*
chain
->
rgpElement
[
i
];
element
->
pCertContext
=
CertDuplicateCertificateContext
(
chain
->
rgpElement
[
i
]
->
pCertContext
);
/* Reset the trust status of the copied element, it'll get
...
...
dlls/crypt32/msg.c
View file @
70c4b667
...
...
@@ -78,7 +78,7 @@ static inline void CryptMsgBase_Init(CryptMsgBase *msg, DWORD dwFlags,
if
(
pStreamInfo
)
{
msg
->
streamed
=
TRUE
;
m
emcpy
(
&
msg
->
stream_info
,
pStreamInfo
,
sizeof
(
msg
->
stream_info
))
;
m
sg
->
stream_info
=
*
pStreamInfo
;
}
else
{
...
...
@@ -1124,7 +1124,7 @@ static BOOL CSignedEncodeMsg_GetParam(HCRYPTMSG hCryptMsg, DWORD dwParamType,
CRYPT_SIGNED_INFO
info
;
char
oid_rsa_data
[]
=
szOID_RSA_data
;
memcpy
(
&
info
,
msg
->
msg_data
.
info
,
sizeof
(
info
))
;
info
=
*
msg
->
msg_data
.
info
;
/* Quirk: OID is only encoded messages if an update has happened */
if
(
msg
->
base
.
state
!=
MsgStateInit
)
info
.
content
.
pszObjId
=
oid_rsa_data
;
...
...
dlls/crypt32/sip.c
View file @
70c4b667
...
...
@@ -325,7 +325,7 @@ BOOL WINAPI CryptSIPRetrieveSubjectGuid
dos
=
(
IMAGE_DOS_HEADER
*
)
pMapped
;
if
(
dos
->
e_magic
==
IMAGE_DOS_SIGNATURE
)
{
memcpy
(
pgSubject
,
&
unknown
,
sizeof
(
GUID
))
;
*
pgSubject
=
unknown
;
SetLastError
(
S_OK
);
bRet
=
TRUE
;
goto
cleanup1
;
...
...
@@ -435,8 +435,8 @@ static void CRYPT_CacheSIP(const GUID *pgSubject, SIP_DISPATCH_INFO *info)
if
(
prov
)
{
memcpy
(
&
prov
->
subject
,
pgSubject
,
sizeof
(
prov
->
subject
))
;
memcpy
(
&
prov
->
info
,
info
,
sizeof
(
prov
->
info
))
;
prov
->
subject
=
*
pgSubject
;
prov
->
info
=
*
info
;
EnterCriticalSection
(
&
providers_cs
);
list_add_tail
(
&
providers
,
&
prov
->
entry
);
LeaveCriticalSection
(
&
providers_cs
);
...
...
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