From 113ccb1a532febf32274bf8561adf303c7f90c6e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Mon, 15 Oct 2012 10:53:58 +0200 Subject: hlsdemux: Also cancel the downloader before stopping the playlist update task --- gst/hls/gsthlsdemux.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'gst/hls') diff --git a/gst/hls/gsthlsdemux.c b/gst/hls/gsthlsdemux.c index da1192f37..eb18a258d 100644 --- a/gst/hls/gsthlsdemux.c +++ b/gst/hls/gsthlsdemux.c @@ -139,6 +139,7 @@ gst_hls_demux_dispose (GObject * obj) if (demux->updates_task) { if (GST_TASK_STATE (demux->updates_task) != GST_TASK_STOPPED) { GST_DEBUG_OBJECT (demux, "Leaving updates task"); + gst_uri_downloader_cancel (demux->downloader); gst_task_stop (demux->updates_task); g_mutex_lock (&demux->updates_timed_lock); GST_TASK_SIGNAL (demux->updates_task); @@ -323,6 +324,7 @@ gst_hls_demux_change_state (GstElement * element, GstStateChange transition) switch (transition) { case GST_STATE_CHANGE_PLAYING_TO_PAUSED: + gst_uri_downloader_cancel (demux->downloader); gst_task_stop (demux->updates_task); g_mutex_lock (&demux->updates_timed_lock); GST_TASK_SIGNAL (demux->updates_task); @@ -628,6 +630,7 @@ gst_hls_demux_stop (GstHLSDemux * demux) if (GST_TASK_STATE (demux->updates_task) != GST_TASK_STOPPED) { demux->stop_stream_task = TRUE; + gst_uri_downloader_cancel (demux->downloader); gst_task_stop (demux->updates_task); g_mutex_lock (&demux->updates_timed_lock); GST_TASK_SIGNAL (demux->updates_task); -- cgit v1.2.1