summaryrefslogtreecommitdiffstats
path: root/src/audio_core
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2023-06-06 06:43:43 +0200
committerGitHub <noreply@github.com>2023-06-06 06:43:43 +0200
commitcb95d7fe1b6d81899fe6b279400da2c991e3132c (patch)
treea856ac45b1053009c4c11ee141c49d7faa4c8a19 /src/audio_core
parentMerge pull request #10611 from liamwhite/audio-deadlock (diff)
parentMerge pull request #10633 from t895/variable-surface-ratio (diff)
downloadyuzu-cb95d7fe1b6d81899fe6b279400da2c991e3132c.tar
yuzu-cb95d7fe1b6d81899fe6b279400da2c991e3132c.tar.gz
yuzu-cb95d7fe1b6d81899fe6b279400da2c991e3132c.tar.bz2
yuzu-cb95d7fe1b6d81899fe6b279400da2c991e3132c.tar.lz
yuzu-cb95d7fe1b6d81899fe6b279400da2c991e3132c.tar.xz
yuzu-cb95d7fe1b6d81899fe6b279400da2c991e3132c.tar.zst
yuzu-cb95d7fe1b6d81899fe6b279400da2c991e3132c.zip
Diffstat (limited to 'src/audio_core')
-rw-r--r--src/audio_core/sink/sink_stream.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/audio_core/sink/sink_stream.cpp b/src/audio_core/sink/sink_stream.cpp
index f44fedfd5..5d58b950c 100644
--- a/src/audio_core/sink/sink_stream.cpp
+++ b/src/audio_core/sink/sink_stream.cpp
@@ -273,10 +273,13 @@ void SinkStream::WaitFreeSpace(std::stop_token stop_token) {
std::unique_lock lk{release_mutex};
release_cv.wait_for(lk, std::chrono::milliseconds(5),
[this]() { return queued_buffers < max_queue_size; });
+#ifndef ANDROID
+ // This wait can cause a problematic shutdown hang on Android.
if (queued_buffers > max_queue_size + 3) {
Common::CondvarWait(release_cv, lk, stop_token,
[this] { return queued_buffers < max_queue_size; });
}
+#endif
}
} // namespace AudioCore::Sink