mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-25 17:10:23 +00:00
AudioServer: Remove any pending mixer queues whose client disconnected
We were pumping the sound device full of silence even after the last audio client disconnected.
This commit is contained in:
parent
11d49aedd8
commit
823ee63095
Notes:
sideshowbarker
2024-07-19 10:46:03 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/823ee63095a
1 changed files with 2 additions and 0 deletions
|
@ -49,6 +49,8 @@ void ASMixer::mix()
|
|||
continue;
|
||||
}
|
||||
|
||||
active_mix_queues.remove_all_matching([&](auto& entry) { return !entry->client(); });
|
||||
|
||||
ASample mixed_buffer[1024];
|
||||
auto mixed_buffer_length = (int)(sizeof(mixed_buffer) / sizeof(ASample));
|
||||
|
||||
|
|
Loading…
Reference in a new issue