[FFmpeg-devel] [PATCH] avfilter/split: switch to activate()

Nicolas George george at nsup.org
Sun Mar 6 16:08:36 EET 2022


Paul B Mahol (12022-03-01):
> Signed-off-by: Paul B Mahol <onemda at gmail.com>
> ---
> 
> Fix possible hangs if (a)split filter is used in graph and one of outputs ends
> earlier than others.
> Then filter may never receive EOF from input provided by (a)split filter.
> 
> See ticket #9152 for commands how to reproduce issue.
> 
> ---
>  libavfilter/split.c | 68 +++++++++++++++++++++++++++++++++------------
>  1 file changed, 51 insertions(+), 17 deletions(-)

Ok, the problem is in forward_status_change() in avfilter.c: it makes a
request on the first output, that triggers the status change on the
input, and therefore it considers itself satisfied without making a
request on the other outputs.

It could be changed to make at least one round and requesting on each
output, but it would be inefficient for filters that have several
outputs connected to different inputs, and that is a more common case.

Therefore, I agree, filters with several outputs connected to the same
input like split need a real activate implementation.

Patch ok, I did not look very carefully at the code itself.

Can you disclose why it was so urgent to push a fix for a but seven
months old that you would rather be rude than wait a few days?

-- 
  Nicolas George
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20220306/6124bcd2/attachment.sig>


More information about the ffmpeg-devel mailing list