output/Thread: move Close() call out of Disable()

This commit is contained in:
Max Kellermann 2017-06-08 09:34:24 +02:00
parent d600b937f1
commit 669d7a6feb

View File

@ -77,9 +77,6 @@ AudioOutput::Enable()
inline void
AudioOutput::Disable() noexcept
{
if (open)
Close(false);
if (really_enabled) {
really_enabled = false;
@ -206,6 +203,9 @@ AudioOutput::OpenOutputAndConvert(AudioFormat desired_audio_format)
inline void
AudioOutputControl::InternalDisable() noexcept
{
if (output->open)
output->Close(false);
output->Disable();
}