output/alsa: rethrow errors in Drain()
This commit is contained in:
parent
a6e5873443
commit
5dfdc15f93
|
@ -762,12 +762,19 @@ AlsaOutput::Drain()
|
||||||
{
|
{
|
||||||
const std::lock_guard<Mutex> lock(mutex);
|
const std::lock_guard<Mutex> lock(mutex);
|
||||||
|
|
||||||
|
if (error)
|
||||||
|
std::rethrow_exception(error);
|
||||||
|
|
||||||
drain = true;
|
drain = true;
|
||||||
|
|
||||||
UnlockActivate();
|
UnlockActivate();
|
||||||
|
|
||||||
while (drain && !error)
|
while (drain) {
|
||||||
|
if (error)
|
||||||
|
std::rethrow_exception(error);
|
||||||
|
|
||||||
cond.wait(mutex);
|
cond.wait(mutex);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void
|
inline void
|
||||||
|
|
Loading…
Reference in New Issue