mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
avformat/nutdec: Check get_packetheader() in mainheader
Fixes; Timeout Fixes: 48794/clusterfuzz-testcase-minimized-ffmpeg_dem_NUT_fuzzer-6524604713140224 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
744ad45c44
commit
b5de084aa6
@ -200,6 +200,8 @@ static int decode_main_header(NUTContext *nut)
|
||||
int tmp_stream, tmp_mul, tmp_pts, tmp_size, tmp_res, tmp_head_idx;
|
||||
|
||||
length = get_packetheader(nut, bc, 1, MAIN_STARTCODE);
|
||||
if (length == (uint64_t)-1)
|
||||
return AVERROR_INVALIDDATA;
|
||||
end = length + avio_tell(bc);
|
||||
|
||||
nut->version = ffio_read_varlen(bc);
|
||||
|
Loading…
Reference in New Issue
Block a user