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
5b072fbb
Commit
5b072fbb
authored
Dec 26, 2007
by
Rob Shearman
Committed by
Alexandre Julliard
Dec 26, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Fix several memory leaks after using IEnumSTATSTG_Next.
The pwcsName field of STATSTG must be freed, otherwise the memory will be leaked.
parent
1f563592
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
0 deletions
+7
-0
streams.c
dlls/msi/streams.c
+5
-0
table.c
dlls/msi/table.c
+2
-0
No files found.
dlls/msi/streams.c
View file @
5b072fbb
...
...
@@ -408,17 +408,22 @@ static UINT add_streams_to_table(MSISTREAMSVIEW *sv)
/* table streams are not in the _Streams table */
if
(
*
stat
.
pwcsName
==
0x4840
)
{
CoTaskMemFree
(
stat
.
pwcsName
);
continue
;
}
stream
=
create_stream
(
sv
,
stat
.
pwcsName
,
TRUE
,
NULL
);
if
(
!
stream
)
{
count
=
-
1
;
CoTaskMemFree
(
stat
.
pwcsName
);
break
;
}
IStorage_OpenStream
(
sv
->
db
->
storage
,
stat
.
pwcsName
,
0
,
STGM_READ
|
STGM_SHARE_EXCLUSIVE
,
0
,
&
stream
->
stream
);
CoTaskMemFree
(
stat
.
pwcsName
);
if
(
!
add_stream_to_table
(
sv
,
stream
,
count
++
))
{
...
...
dlls/msi/table.c
View file @
5b072fbb
...
...
@@ -265,6 +265,7 @@ void enum_stream_names( IStorage *stg )
decode_streamname
(
stat
.
pwcsName
,
name
);
TRACE
(
"stream %2d -> %s %s
\n
"
,
n
,
debugstr_w
(
stat
.
pwcsName
),
debugstr_w
(
name
)
);
CoTaskMemFree
(
stat
.
pwcsName
);
n
++
;
}
...
...
@@ -2577,6 +2578,7 @@ UINT msi_table_apply_transform( MSIDATABASE *db, IStorage *stg )
break
;
decode_streamname
(
stat
.
pwcsName
,
name
);
CoTaskMemFree
(
stat
.
pwcsName
);
if
(
name
[
0
]
!=
0x4840
)
continue
;
...
...
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