diff options
author | Max Kellermann <max@musicpd.org> | 2017-02-09 21:24:20 +0100 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2017-02-09 21:24:20 +0100 |
commit | 67a958a3262d37892a5043fc6216c1d8d9f65b1c (patch) | |
tree | be3dc099c1bd62adaecb2b143cb8f822280ae198 /src/input | |
parent | 38507165221cdf0cc5c76020658b8c69d2a31dbe (diff) | |
parent | 7372c931b3d1cbf4237b37750aa76602fc0382e7 (diff) |
Merge branch 'v0.20.x'
Diffstat (limited to 'src/input')
-rw-r--r-- | src/input/plugins/AlsaInputPlugin.cxx | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/input/plugins/AlsaInputPlugin.cxx b/src/input/plugins/AlsaInputPlugin.cxx index c16016c78..fbbd15176 100644 --- a/src/input/plugins/AlsaInputPlugin.cxx +++ b/src/input/plugins/AlsaInputPlugin.cxx @@ -99,12 +99,8 @@ public: } ~AlsaInputStream() { - /* ClearSocketList must be called from within the - IOThread; if we don't do it manually here, the - ~MultiSocketMonitor() will do it in the current - thread */ BlockingCall(MultiSocketMonitor::GetEventLoop(), [this](){ - ClearSocketList(); + MultiSocketMonitor::Reset(); }); snd_pcm_close(capture_handle); @@ -182,7 +178,7 @@ AlsaInputStream::PrepareSockets() } int count = snd_pcm_poll_descriptors_count(capture_handle); - if (count < 0) { + if (count <= 0) { ClearSocketList(); return std::chrono::steady_clock::duration(-1); } |