mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-03-17 20:17:55 +02:00
avformat/matroskadec: Check for EOF in resync loop
Fixes: Timeout (too long -> instantly) Fixes: 29136/clusterfuzz-testcase-minimized-ffmpeg_dem_WEBM_DASH_MANIFEST_fuzzer-4586141227548672 Reviewed-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 5282147d0c92ac821e85b93e2db6704f4720e0c1) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
e9871b10a9
commit
f7e195bdd3
@ -2620,6 +2620,8 @@ static int matroska_read_header(AVFormatContext *s)
|
||||
goto fail;
|
||||
pos = avio_tell(matroska->ctx->pb);
|
||||
res = ebml_parse(matroska, matroska_segment, matroska);
|
||||
if (res == AVERROR(EIO)) // EOF is translated to EIO, this exists the loop on EOF
|
||||
goto fail;
|
||||
}
|
||||
matroska_execute_seekhead(matroska);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user