summaryrefslogtreecommitdiff
path: root/src/output
diff options
context:
space:
mode:
authorMax Kellermann <max@musicpd.org>2018-01-04 08:41:15 +0100
committerMax Kellermann <max@musicpd.org>2018-01-04 08:41:19 +0100
commit8322ae5a4c9cb44c11a7d69a55988a7c7ab3e8cf (patch)
treec8d29847a2acb2a7b8a8b9a66f6a4b4eb29d4b90 /src/output
parent98a7c62d7a4f716d90af6d78e18d1a3b10bc54b3 (diff)
output/Control: use class ScopeUnlock()
Diffstat (limited to 'src/output')
-rw-r--r--src/output/Control.cxx3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/output/Control.cxx b/src/output/Control.cxx
index 8b56cf142..a2193e08c 100644
--- a/src/output/Control.cxx
+++ b/src/output/Control.cxx
@@ -111,9 +111,8 @@ void
AudioOutputControl::WaitForCommand() noexcept
{
while (!IsCommandFinished()) {
- mutex.unlock();
+ const ScopeUnlock unlock(mutex);
audio_output_client_notify.Wait();
- mutex.lock();
}
}