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
38111eb3
Commit
38111eb3
authored
Sep 13, 2023
by
Alex Henrie
Committed by
Alexandre Julliard
Sep 14, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winmm: Avoid explicitly casting the pointer returned from Heap(Re)Alloc.
parent
c57f5d98
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
8 deletions
+10
-8
lolvldrv.c
dlls/winmm/lolvldrv.c
+10
-8
No files found.
dlls/winmm/lolvldrv.c
View file @
38111eb3
...
@@ -334,6 +334,8 @@ static BOOL MMDRV_InitPerType(LPWINE_MM_DRIVER lpDrv, UINT type, UINT wMsg)
...
@@ -334,6 +334,8 @@ static BOOL MMDRV_InitPerType(LPWINE_MM_DRIVER lpDrv, UINT type, UINT wMsg)
DWORD
ret
;
DWORD
ret
;
UINT
count
=
0
;
UINT
count
=
0
;
int
i
,
k
;
int
i
,
k
;
WINE_MLD
*
mem
;
TRACE
(
"(%p, %04x, %04x)
\n
"
,
lpDrv
,
type
,
wMsg
);
TRACE
(
"(%p, %04x, %04x)
\n
"
,
lpDrv
,
type
,
wMsg
);
part
->
nIDMin
=
part
->
nIDMax
=
0
;
part
->
nIDMin
=
part
->
nIDMax
=
0
;
...
@@ -370,14 +372,14 @@ static BOOL MMDRV_InitPerType(LPWINE_MM_DRIVER lpDrv, UINT type, UINT wMsg)
...
@@ -370,14 +372,14 @@ static BOOL MMDRV_InitPerType(LPWINE_MM_DRIVER lpDrv, UINT type, UINT wMsg)
part
->
nIDMin
,
part
->
nIDMax
,
llTypes
[
type
].
wMaxId
,
part
->
nIDMin
,
part
->
nIDMax
,
llTypes
[
type
].
wMaxId
,
lpDrv
->
drvname
,
llTypes
[
type
].
typestr
);
lpDrv
->
drvname
,
llTypes
[
type
].
typestr
);
/* realloc translation table */
/* realloc translation table */
if
(
llTypes
[
type
].
lpMlds
)
if
(
llTypes
[
type
].
lpMlds
)
{
llTypes
[
type
].
lpMlds
=
(
LPWINE_MLD
)
mem
=
llTypes
[
type
].
lpMlds
-
1
;
HeapReAlloc
(
GetProcessHeap
(),
0
,
llTypes
[
type
].
lpMlds
-
1
,
mem
=
HeapReAlloc
(
GetProcessHeap
(),
0
,
mem
,
sizeof
(
WINE_MLD
)
*
(
llTypes
[
type
].
wMaxId
+
1
));
sizeof
(
WINE_MLD
)
*
(
llTypes
[
type
].
wMaxId
+
1
))
+
1
;
llTypes
[
type
].
lpMlds
=
mem
+
1
;
else
}
else
{
llTypes
[
type
].
lpMlds
=
(
LPWINE_MLD
)
mem
=
HeapAlloc
(
GetProcessHeap
(),
0
,
sizeof
(
WINE_MLD
)
*
(
llTypes
[
type
].
wMaxId
+
1
));
HeapAlloc
(
GetProcessHeap
(),
0
,
llTypes
[
type
].
lpMlds
=
mem
+
1
;
sizeof
(
WINE_MLD
)
*
(
llTypes
[
type
].
wMaxId
+
1
))
+
1
;
}
/* re-build the translation table */
/* re-build the translation table */
if
(
lpDrv
->
bIsMapper
)
{
if
(
lpDrv
->
bIsMapper
)
{
...
...
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