1
0
Fork 0
mirror of https://github.com/LadybirdBrowser/ladybird.git synced 2025-06-10 18:10:56 +09:00

LibAudio: Only join the background enqueuer thread if has been started

This prevent an assertion failure in SoundPlayer when closing it before
trying to play any audio files.
This commit is contained in:
Andrew Kaster 2022-12-24 22:39:22 -07:00 committed by Andreas Kling
parent 18c559b0e3
commit 140000f37a
Notes: sideshowbarker 2024-07-17 03:45:48 +09:00

View file

@ -55,7 +55,8 @@ void ConnectionToServer::die()
m_enqueuer_loop->quit(0);
}
}
(void)m_background_audio_enqueuer->join();
if (m_background_audio_enqueuer->is_started())
(void)m_background_audio_enqueuer->join();
}
ErrorOr<void> ConnectionToServer::async_enqueue(FixedArray<Sample>&& samples)