You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-10 06:10:52 +02:00
avformat/iamf_parse: Check output_channel_count
Fixes: -nan is outside the range of representable values of type 'int' Fixes: 377072730/clusterfuzz-testcase-minimized-ffmpeg_dem_IAMF_fuzzer-6545416570601472 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:
@@ -422,7 +422,7 @@ static int ambisonics_config(void *s, AVIOContext *pb,
|
|||||||
|
|
||||||
output_channel_count = avio_r8(pb); // C
|
output_channel_count = avio_r8(pb); // C
|
||||||
substream_count = avio_r8(pb); // N
|
substream_count = avio_r8(pb); // N
|
||||||
if (audio_element->nb_substreams != substream_count)
|
if (audio_element->nb_substreams != substream_count || output_channel_count == 0)
|
||||||
return AVERROR_INVALIDDATA;
|
return AVERROR_INVALIDDATA;
|
||||||
|
|
||||||
order = floor(sqrt(output_channel_count - 1));
|
order = floor(sqrt(output_channel_count - 1));
|
||||||
|
Reference in New Issue
Block a user