diff --git a/src/output/Control.cxx b/src/output/Control.cxx index ec0430a1e..2edcd7ca5 100644 --- a/src/output/Control.cxx +++ b/src/output/Control.cxx @@ -226,6 +226,7 @@ AudioOutputControl::Open(const AudioFormat audio_format, const bool open2 = open; if (open2 && output->mixer != nullptr) { + const ScopeUnlock unlock(mutex); try { mixer_open(output->mixer); } catch (...) { diff --git a/src/output/Thread.cxx b/src/output/Thread.cxx index c8e90f726..3fb17ae54 100644 --- a/src/output/Thread.cxx +++ b/src/output/Thread.cxx @@ -501,5 +501,6 @@ AudioOutputControl::StartThread() { assert(command == Command::NONE); + const ScopeUnlock unlock(mutex); thread.Start(); }