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
5a556de5
Commit
5a556de5
authored
Feb 12, 2009
by
Andrew Talbot
Committed by
Alexandre Julliard
Feb 13, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winemp3.acm: Replace malloc() with HeapAlloc().
parent
8f1a3e4e
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
7 deletions
+10
-7
interface.c
dlls/winemp3.acm/interface.c
+10
-7
No files found.
dlls/winemp3.acm/interface.c
View file @
5a556de5
...
...
@@ -18,8 +18,11 @@
#include "config.h"
#include <stdlib.h>
#include <stdarg.h>
#include <stdio.h>
#include "windef.h"
#include "winbase.h"
#include "wine/debug.h"
#include "mpg123.h"
#include "mpglib.h"
...
...
@@ -57,9 +60,9 @@ void ClearMP3Buffer(struct mpstr *mp)
b
=
mp
->
tail
;
while
(
b
)
{
free
(
b
->
pnt
);
HeapFree
(
GetProcessHeap
(),
0
,
b
->
pnt
);
bn
=
b
->
next
;
free
(
b
);
HeapFree
(
GetProcessHeap
(),
0
,
b
);
b
=
bn
;
}
mp
->
tail
=
NULL
;
...
...
@@ -71,14 +74,14 @@ static struct buf *addbuf(struct mpstr *mp,const unsigned char *buf,int size)
{
struct
buf
*
nbuf
;
nbuf
=
malloc
(
sizeof
(
struct
buf
)
);
nbuf
=
HeapAlloc
(
GetProcessHeap
(),
0
,
sizeof
(
struct
buf
)
);
if
(
!
nbuf
)
{
WARN
(
"Out of memory!
\n
"
);
return
NULL
;
}
nbuf
->
pnt
=
malloc
(
size
);
nbuf
->
pnt
=
HeapAlloc
(
GetProcessHeap
(),
0
,
size
);
if
(
!
nbuf
->
pnt
)
{
free
(
nbuf
);
HeapFree
(
GetProcessHeap
(),
0
,
nbuf
);
WARN
(
"Out of memory!
\n
"
);
return
NULL
;
}
...
...
@@ -112,8 +115,8 @@ static void remove_buf(struct mpstr *mp)
mp
->
tail
=
mp
->
head
=
NULL
;
}
free
(
buf
->
pnt
);
free
(
buf
);
HeapFree
(
GetProcessHeap
(),
0
,
buf
->
pnt
);
HeapFree
(
GetProcessHeap
(),
0
,
buf
);
}
...
...
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