aboutsummaryrefslogtreecommitdiffstats
path: root/src/output
diff options
context:
space:
mode:
Diffstat (limited to 'src/output')
-rw-r--r--src/output/pulse_plugin.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/output/pulse_plugin.c b/src/output/pulse_plugin.c
index 3d9292ac7..7d935c50a 100644
--- a/src/output/pulse_plugin.c
+++ b/src/output/pulse_plugin.c
@@ -162,6 +162,9 @@ static void pulse_cancel(void *data)
struct pulse_data *pd = data;
int error;
+ if (pd->s == NULL)
+ return;
+
if (pa_simple_flush(pd->s, &error) < 0)
g_warning("Flush failed in PulseAudio output \"%s\": %s\n",
audio_output_get_name(pd->ao),