avcodec/ilbcdec: fix integer overflow in energy
authorMichael Niedermayer <michael@niedermayer.cc>
Sun, 9 Dec 2018 01:26:18 +0000 (02:26 +0100)
committerMichael Niedermayer <michael@niedermayer.cc>
Sun, 23 Dec 2018 19:24:47 +0000 (20:24 +0100)
commitfbf409cd91aca2b4738c6b5bc963ae6041f26701
tree6844985c29dd4bf5b0519303cd97f50a1eeaa94e
parent4096c670abefdd361fcfd427e163088979871c6c
avcodec/ilbcdec: fix integer overflow in energy

webrtc uses a int32_t like the existing code in ilbcdec

Fixes: signed integer overflow: 2080245063 + 257939661 cannot be represented in type 'int'
Fixes: 11037/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_ILBC_fuzzer-5682976612941824

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