flvmux: Return NEED_DATA when we drop a buffer
authorVivia Nikolaidou <vivia@ahiru.eu>
Mon, 10 Aug 2020 17:20:53 +0000 (20:20 +0300)
committerVivia Nikolaidou <vivia@ahiru.eu>
Mon, 10 Aug 2020 17:36:51 +0000 (20:36 +0300)
commitc95cc6a015e1880dd3d74abcffc1b2c346e8f423
treebda092ba22596c43f35931ee9bc3e294c7a70287
parent75f6ca8a11684757a4751edeae1964b24c9cbb6b
flvmux: Return NEED_DATA when we drop a buffer

When we are dropping a buffer in find_best_pad (e.g. waiting for a
keyframe, or skipping backwards timestamp), return
GST_AGGREGATOR_FLOW_NEED_DATA to make sure we have enough data at the
next run. Otherwise, a stream that accidentally fell behind (e.g.
relinking race, or just waiting for a keyframe) will never get the
opportunity to catch up to the other one, because the other one will
always keep advancing.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/696>
gst/flv/gstflvmux.c