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
349abe99
Commit
349abe99
authored
May 20, 2008
by
Jörg Höhle
Committed by
Alexandre Julliard
May 21, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dsound: Fix off by 1 heap error in DSOUND_MixerVol.
parent
3d5ea201
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
mixer.c
dlls/dsound/mixer.c
+2
-2
No files found.
dlls/dsound/mixer.c
View file @
349abe99
...
...
@@ -469,7 +469,7 @@ static LPBYTE DSOUND_MixerVol(const IDirectSoundBufferImpl *dsb, INT len)
case
8
:
/* 8-bit WAV is unsigned, but we need to operate */
/* on signed data for this to work properly */
for
(
i
=
0
;
i
<
len
;
i
+=
2
)
{
for
(
i
=
0
;
i
<
len
-
1
;
i
+=
2
)
{
*
(
bpc
++
)
=
(((
*
(
mem
++
)
-
128
)
*
vLeft
)
>>
16
)
+
128
;
*
(
bpc
++
)
=
(((
*
(
mem
++
)
-
128
)
*
vRight
)
>>
16
)
+
128
;
}
...
...
@@ -478,7 +478,7 @@ static LPBYTE DSOUND_MixerVol(const IDirectSoundBufferImpl *dsb, INT len)
break
;
case
16
:
/* 16-bit WAV is signed -- much better */
for
(
i
=
0
;
i
<
len
;
i
+=
4
)
{
for
(
i
=
0
;
i
<
len
-
3
;
i
+=
4
)
{
*
(
bps
++
)
=
(
*
(
mems
++
)
*
vLeft
)
>>
16
;
*
(
bps
++
)
=
(
*
(
mems
++
)
*
vRight
)
>>
16
;
}
...
...
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