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
f059013a
Commit
f059013a
authored
Jul 03, 2022
by
Nikolay Sivov
Committed by
Alexandre Julliard
Jul 05, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winemsibuilder: Use CRT allocation functions.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
parent
56759946
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
main.c
programs/winemsibuilder/main.c
+5
-5
No files found.
programs/winemsibuilder/main.c
View file @
f059013a
...
...
@@ -77,7 +77,7 @@ static int import_tables( const WCHAR *msifile, WCHAR **tables )
if
(
r
!=
ERROR_SUCCESS
)
return
1
;
len
=
GetCurrentDirectoryW
(
0
,
NULL
);
if
(
!
(
dir
=
HeapAlloc
(
GetProcessHeap
(),
0
,
(
len
+
1
)
*
sizeof
(
WCHAR
)
)))
if
(
!
(
dir
=
malloc
(
(
len
+
1
)
*
sizeof
(
WCHAR
)
)))
{
MsiCloseHandle
(
hdb
);
return
1
;
...
...
@@ -102,7 +102,7 @@ static int import_tables( const WCHAR *msifile, WCHAR **tables )
WINE_ERR
(
"failed to commit changes (%u)
\n
"
,
r
);
}
HeapFree
(
GetProcessHeap
(),
0
,
dir
);
free
(
dir
);
MsiCloseHandle
(
hdb
);
return
(
r
!=
ERROR_SUCCESS
);
}
...
...
@@ -135,7 +135,7 @@ static WCHAR *encode_stream( const WCHAR *in )
return
NULL
;
count
+=
2
;
if
(
!
(
out
=
HeapAlloc
(
GetProcessHeap
(),
0
,
count
*
sizeof
(
WCHAR
)
)))
return
NULL
;
if
(
!
(
out
=
malloc
(
count
*
sizeof
(
WCHAR
)
)))
return
NULL
;
p
=
out
;
while
(
count
--
)
{
...
...
@@ -162,7 +162,7 @@ static WCHAR *encode_stream( const WCHAR *in )
}
*
p
++
=
c
;
}
HeapFree
(
GetProcessHeap
(),
0
,
out
);
free
(
out
);
return
NULL
;
}
...
...
@@ -236,7 +236,7 @@ static int add_stream( const WCHAR *msifile, const WCHAR *stream, const WCHAR *f
ret
=
0
;
done:
HeapFree
(
GetProcessHeap
(),
0
,
encname
);
free
(
encname
);
if
(
stm
)
IStream_Release
(
stm
);
IStorage_Release
(
stg
);
return
ret
;
...
...
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