[FFmpeg-devel] [PATCH] libavformat/mov:the "stco" box parse no need return eof.

tiejun.peng tiejun.peng at foxmail.com
Sun Nov 19 16:00:29 EET 2017


if return eof, will cause to play the whole mp4 file fail.
For example, currently the whole file will play fail
when a few bytes missed in the "stco" box
and the "stco" box is the last box of MP4 file,
Actually the almost media frames can play success at most time.
A few words missed in "stco" box and the other box data is full
will not cause the whole mp4 file fail.

Signed-off-by: tiejun.peng <tiejun.peng at foxmail.com>
---
 libavformat/mov.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/libavformat/mov.c b/libavformat/mov.c
index 5c9f926..78b7bf7 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -1989,9 +1989,6 @@ static int mov_read_stco(MOVContext *c, AVIOContext *pb, MOVAtom atom)
 
     sc->chunk_count = i;
 
-    if (pb->eof_reached)
-        return AVERROR_EOF;
-
     return 0;
 }
 
-- 
2.7.4






More information about the ffmpeg-devel mailing list