Never deadlock ever again thanks

This commit is contained in:
Lior Halphon 2021-12-29 17:03:44 +02:00
parent 97652b7460
commit 38eafeb0cf

View File

@ -390,7 +390,7 @@ static void infraredStateChanged(GB_gameboy_t *gb, bool on)
if (audioBufferPosition < nFrames) { if (audioBufferPosition < nFrames) {
audioBufferNeeded = nFrames; audioBufferNeeded = nFrames;
[audioLock wait]; [audioLock waitUntilDate:[NSDate dateWithTimeIntervalSinceNow:0.125]];
} }
if (stopping || GB_debugger_is_stopped(&gb)) { if (stopping || GB_debugger_is_stopped(&gb)) {