diff options
Diffstat (limited to '')
-rw-r--r-- | src/output_all.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/output_all.c b/src/output_all.c index 08f4ee0dc..bdf0385bb 100644 --- a/src/output_all.c +++ b/src/output_all.c @@ -445,10 +445,15 @@ audio_output_all_check(void) bool audio_output_all_wait(unsigned threshold) { - if (audio_output_all_check() < threshold) + player_lock(); + + if (audio_output_all_check() < threshold) { + player_unlock(); return true; + } - notify_wait(&pc.notify); + player_wait(); + player_unlock(); return audio_output_all_check() < threshold; } |