basesrc: Flush-stop starts live task in paused

The flush-stop event should not restart the task for live sources unless
the element is playing. This was breaking seeks in pause with the rtpsrc.

https://bugzilla.gnome.org/show_bug.cgi?id=635701
This commit is contained in:
Nicolas Dufresne 2015-03-27 18:20:37 -04:00
parent ae0b2ec46b
commit 208696a774

View file

@ -1800,6 +1800,12 @@ gst_base_src_send_event (GstElement * element, GstEvent * event)
GST_OBJECT_LOCK (src->srcpad);
start = (GST_PAD_MODE (src->srcpad) == GST_PAD_MODE_PUSH);
GST_OBJECT_UNLOCK (src->srcpad);
if (src->is_live) {
if (!src->live_running)
start = FALSE;
}
if (start)
gst_pad_start_task (src->srcpad, (GstTaskFunction) gst_base_src_loop,
src->srcpad, NULL);