SDL: Fix blip audio buffer repeat while paused

This commit is contained in:
Jeffrey Pfau 2014-12-31 14:51:52 -08:00
parent c141063101
commit eeb7060bda
1 changed files with 1 additions and 1 deletions

View File

@ -97,7 +97,7 @@ static void _GBASDLAudioCallback(void* context, Uint8* data, int len) {
}
GBASyncConsumeAudio(&audioContext->thread->sync);
if (available < len) {
memset(((short*) data) + audioContext->obtainedSpec.channels * available, 0, len - available);
memset(((short*) data) + audioContext->obtainedSpec.channels * available, 0, (len - available) * audioContext->obtainedSpec.channels * sizeof(short));
}
#endif
}