summaryrefslogtreecommitdiff
path: root/gst
diff options
context:
space:
mode:
authorWim Taymans <wim.taymans@collabora.co.uk>2010-02-16 19:53:09 +0100
committerWim Taymans <wim@metal.(none)>2010-02-16 19:54:32 +0100
commita0b651bf5ba51eb385e43d61dd74cb786057d4fd (patch)
tree638cadf8ea12a658942d24f33cff39ff006b9c9a /gst
parentd14685eb083270802459a73e569252bfeb4b40c6 (diff)
rtspsrc: avoid stopping NULL tasks
Check the task for NULL, it could be paused and set to NULL before.
Diffstat (limited to 'gst')
-rw-r--r--gst/rtsp/gstrtspsrc.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/gst/rtsp/gstrtspsrc.c b/gst/rtsp/gstrtspsrc.c
index 281371f70..c99e381cc 100644
--- a/gst/rtsp/gstrtspsrc.c
+++ b/gst/rtsp/gstrtspsrc.c
@@ -3425,7 +3425,10 @@ pause:
GST_DEBUG_OBJECT (src, "pausing task, reason %s", reason);
src->running = FALSE;
- gst_task_pause (src->task);
+ if (src->task) {
+ /* can be NULL when we stopped and unreffed already */
+ gst_task_pause (src->task);
+ }
if (GST_FLOW_IS_FATAL (ret) || ret == GST_FLOW_NOT_LINKED) {
if (ret == GST_FLOW_UNEXPECTED) {
/* perform EOS logic */