aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Alc/backends/pulseaudio.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/Alc/backends/pulseaudio.c b/Alc/backends/pulseaudio.c
index 28858a72..6ba82cd2 100644
--- a/Alc/backends/pulseaudio.c
+++ b/Alc/backends/pulseaudio.c
@@ -876,8 +876,10 @@ static int ALCpulsePlayback_mixerProc(void *ptr)
free_func = pa_xfree;
}
- aluMixData(device, buf, newlen/frame_size);
+ newlen /= frame_size;
+ aluMixData(device, buf, newlen);
+ newlen *= frame_size;
ret = pa_stream_write(self->stream, buf, newlen, free_func, 0, PA_SEEK_RELATIVE);
if(ret != PA_OK)
{