X-Git-Url: https://git.sesse.net/?p=nageru;a=blobdiff_plain;f=alsa_pool.cpp;h=3092dc32335551deed1b2b7b2255c07b7e9a19db;hp=59ae595f029f8ba6cfef0d7aff12f88a97f61799;hb=4e3c52ba57c4552a969e71ccdefd9941ce8d6290;hpb=5327e959225fa2324d443d73746e6614879ff505 diff --git a/alsa_pool.cpp b/alsa_pool.cpp index 59ae595..3092dc3 100644 --- a/alsa_pool.cpp +++ b/alsa_pool.cpp @@ -391,6 +391,10 @@ void ALSAPool::reset_device(unsigned index) { lock_guard lock(mu); Device *device = &devices[index]; + if (device->state == Device::State::DEAD) { + // Not running, and should not be started. + return; + } if (inputs[index] != nullptr) { inputs[index]->stop_capture_thread(); }