discoverer: Switch to playing to handle live URI

Fixes discovery on dvb://
This commit is contained in:
Edward Hervey 2013-09-19 12:58:53 +02:00
parent 71930443cc
commit 556687b94b

View file

@ -1510,6 +1510,12 @@ _setup_locked (GstDiscoverer * dc)
ret = ret =
gst_element_set_state ((GstElement *) dc->priv->pipeline, gst_element_set_state ((GstElement *) dc->priv->pipeline,
GST_STATE_PAUSED); GST_STATE_PAUSED);
if (ret == GST_STATE_CHANGE_NO_PREROLL) {
GST_DEBUG ("Source is live, switching to PLAYING");
ret =
gst_element_set_state ((GstElement *) dc->priv->pipeline,
GST_STATE_PLAYING);
}
DISCO_LOCK (dc); DISCO_LOCK (dc);
GST_DEBUG_OBJECT (dc, "Pipeline going to PAUSED : %s", GST_DEBUG_OBJECT (dc, "Pipeline going to PAUSED : %s",