output/MultipleOutputs: move code to AudioOutput::EnableDisableWait()

This commit is contained in:
Max Kellermann
2016-12-14 08:00:43 +01:00
parent ced3f320eb
commit b107a1583f
2 changed files with 18 additions and 7 deletions

View File

@@ -112,13 +112,7 @@ MultipleOutputs::EnableDisable()
{
for (auto ao : outputs) {
const ScopeLock lock(ao->mutex);
if (ao->enabled != ao->really_enabled) {
if (ao->enabled)
ao->EnableWait();
else
ao->DisableWait();
}
ao->EnableDisableWait();
}
}