mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-18 22:36:33 +00:00
oggdemux: do not throw a flow error on flushing
If the streaming task attempts to read a chain while the pipeline is stopping (which can happen if the pipeline stops shortly after start or a new URI being setup in gapless playback case), it will see a flushing return from upstream, and should then also return flushing to the caller, rather than emit a flow error. https://bugzilla.gnome.org/show_bug.cgi?id=722442
This commit is contained in:
parent
4e44f37abd
commit
9491157f1a
1 changed files with 11 additions and 2 deletions
|
@ -4094,8 +4094,12 @@ gst_ogg_demux_find_chains (GstOggDemux * ogg)
|
|||
* ogg file. */
|
||||
gst_ogg_demux_seek (ogg, 0);
|
||||
ret = gst_ogg_demux_read_chain (ogg, &chain);
|
||||
if (ret != GST_FLOW_OK)
|
||||
goto no_first_chain;
|
||||
if (ret != GST_FLOW_OK) {
|
||||
if (ret == GST_FLOW_FLUSHING)
|
||||
goto flushing;
|
||||
else
|
||||
goto no_first_chain;
|
||||
}
|
||||
|
||||
/* read page from end offset, we use this page to check if its serial
|
||||
* number is contained in the first chain. If this is the case then
|
||||
|
@ -4155,6 +4159,11 @@ no_last_page:
|
|||
gst_ogg_chain_free (chain);
|
||||
return ret;
|
||||
}
|
||||
flushing:
|
||||
{
|
||||
GST_DEBUG_OBJECT (ogg, "Flushing, can't read chain");
|
||||
return GST_FLOW_FLUSHING;
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Loading…
Reference in a new issue