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
713290eb
Commit
713290eb
authored
May 26, 2008
by
Dan Kegel
Committed by
Alexandre Julliard
May 27, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fusion: Use HeapAlloc, not strdup, to avoid malloc/HeapFree mismatch.
parent
b44df3a8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
3 deletions
+10
-3
assembly.c
dlls/fusion/assembly.c
+10
-3
No files found.
dlls/fusion/assembly.c
View file @
713290eb
...
...
@@ -406,7 +406,11 @@ HRESULT assembly_release(ASSEMBLY *assembly)
static
LPSTR
assembly_dup_str
(
ASSEMBLY
*
assembly
,
WORD
index
)
{
return
strdup
((
LPSTR
)
&
assembly
->
strings
[
index
]);
LPSTR
str
=
(
LPSTR
)
&
assembly
->
strings
[
index
];
LPSTR
cpy
=
HeapAlloc
(
GetProcessHeap
(),
0
,
strlen
(
str
)
+
1
);
if
(
cpy
)
strcpy
(
cpy
,
str
);
return
cpy
;
}
HRESULT
assembly_get_name
(
ASSEMBLY
*
assembly
,
LPSTR
*
name
)
...
...
@@ -431,8 +435,11 @@ HRESULT assembly_get_name(ASSEMBLY *assembly, LPSTR *name)
HRESULT
assembly_get_path
(
ASSEMBLY
*
assembly
,
LPSTR
*
path
)
{
*
path
=
strdup
(
assembly
->
path
);
if
(
!*
path
)
LPSTR
cpy
=
HeapAlloc
(
GetProcessHeap
(),
0
,
strlen
(
assembly
->
path
)
+
1
);
*
path
=
cpy
;
if
(
cpy
)
strcpy
(
cpy
,
assembly
->
path
);
else
return
E_OUTOFMEMORY
;
return
S_OK
;
...
...
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