Commit f1b8bcd6 authored by Max Kellermann's avatar Max Kellermann

output/pulse: don't drain if stream is suspended or corked

In this state, we can't make any progress. Closes https://github.com/MusicPlayerDaemon/MPD/issues/1084
parent c2bc3704
...@@ -5,6 +5,7 @@ ver 0.22.5 (not yet released) ...@@ -5,6 +5,7 @@ ver 0.22.5 (not yet released)
- iso9660: another fix for unaligned reads - iso9660: another fix for unaligned reads
* output * output
- httpd: error handling on Windows improved - httpd: error handling on Windows improved
- pulse: fix deadlock with "always_on"
* Windows: * Windows:
- enable https:// support (via Schannel) - enable https:// support (via Schannel)
......
...@@ -830,7 +830,9 @@ PulseOutput::Drain() ...@@ -830,7 +830,9 @@ PulseOutput::Drain()
{ {
Pulse::LockGuard lock(mainloop); Pulse::LockGuard lock(mainloop);
if (pa_stream_get_state(stream) != PA_STREAM_READY) if (pa_stream_get_state(stream) != PA_STREAM_READY ||
pa_stream_is_suspended(stream) ||
pa_stream_is_corked(stream))
return; return;
pa_operation *o = pa_operation *o =
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment