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:
parent
18c559b0e3
commit
140000f37a
Notes:
sideshowbarker
2024-07-17 03:45:48 +09:00
Author: https://github.com/ADKaster
Commit: 140000f37a
Pull-request: https://github.com/SerenityOS/serenity/pull/16657
Reviewed-by: https://github.com/kleinesfilmroellchen ✅
1 changed files with 2 additions and 1 deletions
|
@ -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)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue