Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
20c57466
Commit
20c57466
authored
May 24, 2006
by
Mike McCormack
Committed by
Alexandre Julliard
May 24, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Fix a possible memory leak.
parent
9c018fd8
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
8 deletions
+11
-8
action.c
dlls/msi/action.c
+11
-8
No files found.
dlls/msi/action.c
View file @
20c57466
...
...
@@ -2816,8 +2816,8 @@ static UINT ITERATE_CreateShortcuts(MSIRECORD *row, LPVOID param)
LPCWSTR
buffer
,
extension
;
MSICOMPONENT
*
comp
;
static
const
WCHAR
szlnk
[]
=
{
'.'
,
'l'
,
'n'
,
'k'
,
0
};
IShellLinkW
*
sl
;
IPersistFile
*
pf
;
IShellLinkW
*
sl
=
NULL
;
IPersistFile
*
pf
=
NULL
;
HRESULT
res
;
buffer
=
MSI_RecordGetString
(
row
,
4
);
...
...
@@ -2841,17 +2841,17 @@ static UINT ITERATE_CreateShortcuts(MSIRECORD *row, LPVOID param)
res
=
CoCreateInstance
(
&
CLSID_ShellLink
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IShellLinkW
,
(
LPVOID
*
)
&
sl
);
if
(
FAILED
(
res
))
if
(
FAILED
(
res
))
{
ERR
(
"
Is IID_IShellLink
\n
"
);
return
ERROR_SUCCESS
;
ERR
(
"
CLSID_ShellLink not available
\n
"
);
goto
err
;
}
res
=
IShellLinkW_QueryInterface
(
sl
,
&
IID_IPersistFile
,(
LPVOID
*
)
&
pf
);
if
(
FAILED
(
res
)
)
if
(
FAILED
(
res
)
)
{
ERR
(
"
Is IID_IPersistFile
\n
"
);
return
ERROR_SUCCESS
;
ERR
(
"
QueryInterface(IID_IPersistFile) failed
\n
"
);
goto
err
;
}
buffer
=
MSI_RecordGetString
(
row
,
2
);
...
...
@@ -2937,7 +2937,10 @@ static UINT ITERATE_CreateShortcuts(MSIRECORD *row, LPVOID param)
msi_free
(
target_file
);
err:
if
(
pf
)
IPersistFile_Release
(
pf
);
if
(
sl
)
IShellLinkW_Release
(
sl
);
return
ERROR_SUCCESS
;
...
...
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