avcodec/amr_parser: Treat 0 channels as 1
authorMichael Niedermayer <michael@niedermayer.cc>
Tue, 5 Oct 2021 19:17:54 +0000 (21:17 +0200)
committerMichael Niedermayer <michael@niedermayer.cc>
Thu, 7 Oct 2021 17:37:05 +0000 (19:37 +0200)
commitcc721fc29240fadd0aec5b86cf15b5ffb49f303e
treea0815b34541114d2fa4bf95f17b9903c91c8c58c
parent1831fa72785d46ed2ec5a0c4084866e0089574f4
avcodec/amr_parser: Treat 0 channels as 1

Fixes: division by 0
Fixes: 39562/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_AMRWB_fuzzer-5448834960982016
Fixes: 39589/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_AMRWB_fuzzer-6119205334810624

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavcodec/amr_parser.c