aboutsummaryrefslogtreecommitdiffstats
path: root/src/output_thread.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/output_thread.c')
-rw-r--r--src/output_thread.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/output_thread.c b/src/output_thread.c
index e1f20e580..11dea0845 100644
--- a/src/output_thread.c
+++ b/src/output_thread.c
@@ -351,7 +351,8 @@ static gpointer audio_output_task(gpointer arg)
case AO_COMMAND_CANCEL:
ao->chunk = NULL;
- ao_plugin_cancel(ao->plugin, ao->data);
+ if (ao->open)
+ ao_plugin_cancel(ao->plugin, ao->data);
ao_command_finished(ao);
/* the player thread will now clear our music