Commit 7c8087f4 authored by Nicolas Dufresne's avatar Nicolas Dufresne

basesink: Make sure we never drop the preroll buffer

This is cosmetic as 'late' should never be set during preroll (in pause).
Though code may evolve in the future, so this is good for preventing
potential bugs.
parent 5ca63b7f
......@@ -3476,15 +3476,15 @@ gst_base_sink_chain_unlocked (GstBaseSink * basesink, GstPad * pad,
if (G_UNLIKELY (late))
goto dropped;
/* We are about to prepare the first frame, make sure we have prerolled
* already. This prevent nesting prepare/render calls. */
ret = gst_base_sink_do_preroll (basesink, obj);
if (G_UNLIKELY (ret != GST_FLOW_OK))
goto preroll_failed;
if (G_UNLIKELY (late))
goto dropped;
if (!is_list) {
if (bclass->prepare) {
ret = bclass->prepare (basesink, GST_BUFFER_CAST (obj));
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment