From 6e6fc159a7c22eecbf04086c72cb182bad4ed7d3 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Thu, 13 Dec 2012 14:48:35 +0100 Subject: [PATCH] basesrc: call _stop when start failed When we failed to complete the start, call stop again. This makes sure that all successfull calls to _start are paired with a _stop. Fixes https://bugzilla.gnome.org/show_bug.cgi?id=687845 --- libs/gst/base/gstbasesrc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libs/gst/base/gstbasesrc.c b/libs/gst/base/gstbasesrc.c index a935e2d73c..d845517e84 100644 --- a/libs/gst/base/gstbasesrc.c +++ b/libs/gst/base/gstbasesrc.c @@ -3265,7 +3265,7 @@ seek_failed: { GST_PAD_STREAM_UNLOCK (basesrc->srcpad); GST_ERROR_OBJECT (basesrc, "Failed to perform initial seek"); - gst_base_src_set_flushing (basesrc, TRUE, FALSE, NULL); + gst_base_src_stop (basesrc); if (event) gst_event_unref (event); ret = GST_FLOW_ERROR; @@ -3274,7 +3274,7 @@ seek_failed: no_get_range: { GST_PAD_STREAM_UNLOCK (basesrc->srcpad); - gst_base_src_set_flushing (basesrc, TRUE, FALSE, NULL); + gst_base_src_stop (basesrc); GST_ERROR_OBJECT (basesrc, "Cannot operate in pull mode, stopping"); ret = GST_FLOW_ERROR; goto error;