tagdemux: Propagate flow returns from gst_type_find_helper_get_range() properly

Instead of considering every failed typefinding as an error, even in
case of e.g. GST_FLOW_FLUSHING.
This commit is contained in:
Sebastian Dröge 2018-08-08 12:44:55 +02:00
parent 7757e07f68
commit 0340c7e1f8

View file

@ -1365,11 +1365,13 @@ gst_tag_demux_element_find (GstTagDemux * demux)
if (GST_PAD_MODE (demux->priv->srcpad) == GST_PAD_MODE_PULL) if (GST_PAD_MODE (demux->priv->srcpad) == GST_PAD_MODE_PULL)
goto skip_typefinding; goto skip_typefinding;
caps = gst_type_find_helper_get_range (GST_OBJECT (demux), NULL, ret = gst_type_find_helper_get_range_full (GST_OBJECT (demux), NULL,
(GstTypeFindHelperGetRangeFunction) gst_tag_demux_read_range, (GstTypeFindHelperGetRangeFunction) gst_tag_demux_read_range,
demux->priv->upstream_size demux->priv->upstream_size
- (demux->priv->strip_start + demux->priv->strip_end), NULL, - (demux->priv->strip_start + demux->priv->strip_end), NULL,
&probability); &caps, &probability);
if (ret != GST_FLOW_OK)
goto read_tag_error;
GST_INFO_OBJECT (demux, "Found type %" GST_PTR_FORMAT " with a " GST_INFO_OBJECT (demux, "Found type %" GST_PTR_FORMAT " with a "
"probability of %u", caps, probability); "probability of %u", caps, probability);