output/Thread: fix assertion failure in CLOSE handler

Convert assertion to runtime check; this assertion could fail when the
output was closed due to an error before CLOSE arrived.
This commit is contained in:
Max Kellermann 2016-12-27 07:57:22 +01:00
parent e76573cc1a
commit d6d465cdf4

View File

@ -443,8 +443,7 @@ AudioOutput::Task()
break; break;
case Command::CLOSE: case Command::CLOSE:
assert(open); if (open)
Close(false); Close(false);
CommandFinished(); CommandFinished();
break; break;