mirror of
https://github.com/holub/mame
synced 2025-04-24 09:20:02 +03:00
Merge pull request #2409 from 057a3dd61f99517a3afea0051a49cb27994f94d/sdl-callback-fix
Fix sound_sdl::sdl_callback, fill buffer with silence when underflow.
This commit is contained in:
commit
10f74bb2fe
@ -359,6 +359,7 @@ static void sdl_callback(void *userdata, Uint8 *stream, int len)
|
||||
if (LOG_SOUND)
|
||||
fprintf(sound_log, "Underflow at sdl_callback: SPP=%d SBI=%d(%d) Len=%d\n", (int)thiz->stream_playpos, (int)sb_in, (int)thiz->stream_buffer_in, (int)len);
|
||||
|
||||
memset(stream, 0, len);
|
||||
return;
|
||||
}
|
||||
else if ((thiz->stream_playpos+len) > thiz->stream_buffer_size)
|
||||
|
Loading…
Reference in New Issue
Block a user