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
0a3e5448
Commit
0a3e5448
authored
Nov 22, 2015
by
Nikolay Sivov
Committed by
Alexandre Julliard
Nov 25, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sc: Fix service handle leak on error path (Coverity).
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
53a065ae
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
sc.c
programs/sc/sc.c
+4
-5
No files found.
programs/sc/sc.c
View file @
0a3e5448
...
...
@@ -285,15 +285,14 @@ int wmain( int argc, const WCHAR *argv[] )
if
(
service
)
{
SERVICE_FAILURE_ACTIONSW
sfa
;
if
(
!
parse_failure_params
(
argc
-
3
,
argv
+
3
,
&
sfa
))
if
(
parse_failure_params
(
argc
-
3
,
argv
+
3
,
&
sfa
))
{
WINE_WARN
(
"failed to parse failure parameters
\n
"
);
CloseServiceHandle
(
manager
);
return
1
;
}
ret
=
ChangeServiceConfig2W
(
service
,
SERVICE_CONFIG_FAILURE_ACTIONS
,
&
sfa
);
if
(
!
ret
)
WINE_TRACE
(
"failed to set service failure actions %u
\n
"
,
GetLastError
());
HeapFree
(
GetProcessHeap
(),
0
,
sfa
.
lpsaActions
);
}
else
WINE_WARN
(
"failed to parse failure parameters
\n
"
);
CloseServiceHandle
(
service
);
}
else
WINE_TRACE
(
"failed to open service %u
\n
"
,
GetLastError
());
...
...
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