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
a74aab75
Commit
a74aab75
authored
Sep 22, 2008
by
Juan Lang
Committed by
Alexandre Julliard
Sep 23, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wintrust: Use helper function to allocate CRYPT_PROVIDER_DATA.
parent
30547a45
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
28 additions
and
9 deletions
+28
-9
wintrust_main.c
dlls/wintrust/wintrust_main.c
+28
-9
No files found.
dlls/wintrust/wintrust_main.c
View file @
a74aab75
...
...
@@ -88,15 +88,9 @@ static DWORD WINTRUST_ExecuteSteps(const struct wintrust_step *steps,
return
err
;
}
static
LONG
WINTRUST_DefaultVerify
(
HWND
hwnd
,
GUID
*
actionID
,
WINTRUST_DATA
*
data
)
static
CRYPT_PROVIDER_DATA
*
WINTRUST_AllocateProviderData
(
void
)
{
DWORD
err
=
ERROR_SUCCESS
,
numSteps
=
0
;
CRYPT_PROVIDER_DATA
*
provData
;
BOOL
ret
;
struct
wintrust_step
verifySteps
[
5
];
TRACE
(
"(%p, %s, %p)
\n
"
,
hwnd
,
debugstr_guid
(
actionID
),
data
);
provData
=
WINTRUST_Alloc
(
sizeof
(
CRYPT_PROVIDER_DATA
));
if
(
!
provData
)
...
...
@@ -118,6 +112,33 @@ static LONG WINTRUST_DefaultVerify(HWND hwnd, GUID *actionID,
if
(
!
provData
->
psPfns
)
goto
oom
;
provData
->
psPfns
->
cbStruct
=
sizeof
(
CRYPT_PROVIDER_FUNCTIONS
);
return
provData
;
oom:
if
(
provData
)
{
WINTRUST_Free
(
provData
->
padwTrustStepErrors
);
WINTRUST_Free
(
provData
->
u
.
pPDSip
);
WINTRUST_Free
(
provData
->
psPfns
);
WINTRUST_Free
(
provData
);
}
return
NULL
;
}
static
LONG
WINTRUST_DefaultVerify
(
HWND
hwnd
,
GUID
*
actionID
,
WINTRUST_DATA
*
data
)
{
DWORD
err
=
ERROR_SUCCESS
,
numSteps
=
0
;
CRYPT_PROVIDER_DATA
*
provData
;
BOOL
ret
;
struct
wintrust_step
verifySteps
[
5
];
TRACE
(
"(%p, %s, %p)
\n
"
,
hwnd
,
debugstr_guid
(
actionID
),
data
);
provData
=
WINTRUST_AllocateProviderData
();
if
(
!
provData
)
return
ERROR_OUTOFMEMORY
;
ret
=
WintrustLoadFunctionPointers
(
actionID
,
provData
->
psPfns
);
if
(
!
ret
)
{
...
...
@@ -162,8 +183,6 @@ static LONG WINTRUST_DefaultVerify(HWND hwnd, GUID *actionID,
err
=
WINTRUST_ExecuteSteps
(
verifySteps
,
numSteps
,
provData
);
goto
done
;
oom:
err
=
ERROR_OUTOFMEMORY
;
error:
if
(
provData
)
{
...
...
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