[FFmpeg-devel] [PATCH 17/35] fftools/ffmpeg: do not send spurious EOF for streamcopy when looping

Anton Khirnov anton at khirnov.net
Thu Jun 16 22:55:16 EEST 2022


---
 fftools/ffmpeg.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/fftools/ffmpeg.c b/fftools/ffmpeg.c
index b8a11818b8..53ca8c7f7b 100644
--- a/fftools/ffmpeg.c
+++ b/fftools/ffmpeg.c
@@ -2516,7 +2516,8 @@ static int process_input_packet(InputStream *ist, const AVPacket *pkt, int no_eo
     for (i = 0; i < nb_output_streams; i++) {
         OutputStream *ost = output_streams[i];
 
-        if (!check_output_constraints(ist, ost) || ost->encoding_needed)
+        if (!check_output_constraints(ist, ost) || ost->encoding_needed ||
+            (!pkt && no_eof))
             continue;
 
         do_streamcopy(ist, ost, pkt);
-- 
2.34.1



More information about the ffmpeg-devel mailing list