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
51cf7d13
Commit
51cf7d13
authored
Jan 03, 2005
by
Aric Stewart
Committed by
Alexandre Julliard
Jan 03, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Free allocated buffers.
parent
d5980989
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
43 additions
and
11 deletions
+43
-11
action.c
dlls/msi/action.c
+41
-0
msipriv.h
dlls/msi/msipriv.h
+1
-0
package.c
dlls/msi/package.c
+1
-11
No files found.
dlls/msi/action.c
View file @
51cf7d13
...
...
@@ -423,6 +423,47 @@ void ACTION_remove_tracked_tempfiles(MSIPACKAGE* package)
}
}
/* Called when the package is being closed */
extern
void
ACTION_free_package_structures
(
MSIPACKAGE
*
package
)
{
INT
i
;
TRACE
(
"Freeing package action data
\n
"
);
/* No dynamic buffers in features */
if
(
package
->
features
&&
package
->
loaded_features
>
0
)
HeapFree
(
GetProcessHeap
(),
0
,
package
->
features
);
for
(
i
=
0
;
i
<
package
->
loaded_folders
;
i
++
)
{
HeapFree
(
GetProcessHeap
(),
0
,
package
->
folders
[
i
].
Directory
);
HeapFree
(
GetProcessHeap
(),
0
,
package
->
folders
[
i
].
TargetDefault
);
HeapFree
(
GetProcessHeap
(),
0
,
package
->
folders
[
i
].
SourceDefault
);
HeapFree
(
GetProcessHeap
(),
0
,
package
->
folders
[
i
].
ResolvedTarget
);
HeapFree
(
GetProcessHeap
(),
0
,
package
->
folders
[
i
].
ResolvedSource
);
HeapFree
(
GetProcessHeap
(),
0
,
package
->
folders
[
i
].
Property
);
}
if
(
package
->
folders
&&
package
->
loaded_folders
>
0
)
HeapFree
(
GetProcessHeap
(),
0
,
package
->
folders
);
/* no dynamic buffers in components */
if
(
package
->
components
&&
package
->
loaded_components
>
0
)
HeapFree
(
GetProcessHeap
(),
0
,
package
->
components
);
for
(
i
=
0
;
i
<
package
->
loaded_files
;
i
++
)
{
HeapFree
(
GetProcessHeap
(),
0
,
package
->
files
[
i
].
File
);
HeapFree
(
GetProcessHeap
(),
0
,
package
->
files
[
i
].
FileName
);
HeapFree
(
GetProcessHeap
(),
0
,
package
->
files
[
i
].
Version
);
HeapFree
(
GetProcessHeap
(),
0
,
package
->
files
[
i
].
Language
);
HeapFree
(
GetProcessHeap
(),
0
,
package
->
files
[
i
].
SourcePath
);
HeapFree
(
GetProcessHeap
(),
0
,
package
->
files
[
i
].
TargetPath
);
}
if
(
package
->
files
&&
package
->
loaded_files
>
0
)
HeapFree
(
GetProcessHeap
(),
0
,
package
->
files
);
}
static
UINT
ACTION_OpenQuery
(
MSIDATABASE
*
db
,
MSIQUERY
**
view
,
LPCWSTR
fmt
,
...
)
{
LPWSTR
szQuery
;
...
...
dlls/msi/msipriv.h
View file @
51cf7d13
...
...
@@ -273,6 +273,7 @@ extern UINT read_raw_stream_data( MSIDATABASE*, LPCWSTR stname,
USHORT
**
pdata
,
UINT
*
psz
);
extern
UINT
ACTION_DoTopLevelINSTALL
(
MSIPACKAGE
*
,
LPCWSTR
,
LPCWSTR
);
extern
void
ACTION_remove_tracked_tempfiles
(
MSIPACKAGE
*
);
extern
void
ACTION_free_package_structures
(
MSIPACKAGE
*
);
/* record internals */
extern
UINT
MSI_RecordSetIStream
(
MSIRECORD
*
,
unsigned
int
,
IStream
*
);
...
...
dlls/msi/package.c
View file @
51cf7d13
...
...
@@ -53,18 +53,8 @@ void MSI_FreePackage( MSIOBJECTHDR *arg)
MSIPACKAGE
*
package
=
(
MSIPACKAGE
*
)
arg
;
ACTION_remove_tracked_tempfiles
(
package
);
ACTION_free_package_structures
(
package
);
if
(
package
->
features
&&
package
->
loaded_features
>
0
)
HeapFree
(
GetProcessHeap
(),
0
,
package
->
features
);
if
(
package
->
folders
&&
package
->
loaded_folders
>
0
)
HeapFree
(
GetProcessHeap
(),
0
,
package
->
folders
);
if
(
package
->
components
&&
package
->
loaded_components
>
0
)
HeapFree
(
GetProcessHeap
(),
0
,
package
->
components
);
if
(
package
->
files
&&
package
->
loaded_files
>
0
)
HeapFree
(
GetProcessHeap
(),
0
,
package
->
files
);
msiobj_release
(
&
package
->
db
->
hdr
);
}
...
...
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