]> git.sesse.net Git - ffmpeg/commit
avcodec/utils: Require a non zero channels unless AV_CODEC_CAP_CHANNEL_CONF is set
authorMichael Niedermayer <michael@niedermayer.cc>
Wed, 9 Sep 2020 21:13:02 +0000 (23:13 +0200)
committerMichael Niedermayer <michael@niedermayer.cc>
Fri, 27 Nov 2020 23:41:51 +0000 (00:41 +0100)
commit81503ac58a763a36b1f57264013b1e76acb62b68
tree995710da182b6cabc55c1daa764a69120d0618cb
parent34f5a59ad5aa8baad2036321f63bf1e34ffdefb9
avcodec/utils: Require a non zero channels unless AV_CODEC_CAP_CHANNEL_CONF is set

This avoids per codec checks for channels not being 0

Fixes: division by 0
Fixes: 25419/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FASTAUDIO_fuzzer-5632544761184256
Fixes: 25433/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FASTAUDIO_fuzzer-6215671900536832
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Suggested-by: Paul B Mahol <onemda@gmail.com>
See: [FFmpeg-devel] [PATCH 1/3] avcodec/fastaudio: Check channel
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavcodec/utils.c