]> git.sesse.net Git - nageru/blobdiff - alsa_pool.cpp
Support audio-only FFmpeg inputs. Somewhat wonky, though.
[nageru] / alsa_pool.cpp
index 59ae595f029f8ba6cfef0d7aff12f88a97f61799..3092dc32335551deed1b2b7b2255c07b7e9a19db 100644 (file)
@@ -391,6 +391,10 @@ void ALSAPool::reset_device(unsigned index)
 {
        lock_guard<mutex> 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();
        }