avcodec/loco: Limit lossy parameter so it is sane and does not overflow
authorMichael Niedermayer <michael@niedermayer.cc>
Sat, 15 Jun 2019 19:47:16 +0000 (21:47 +0200)
committerMichael Niedermayer <michael@niedermayer.cc>
Tue, 25 Jun 2019 11:30:09 +0000 (13:30 +0200)
commitce3b0b9066b433564ed3ee3eed3a1e8f2c0834a1
treed2d44c06824495fbcd4a2391ce575d097c97173f
parent696312c487d9d8c49a087017a829d1cdcbd68651
avcodec/loco: Limit lossy parameter so it is sane and does not overflow

Fixes: 15248/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_LOCO_fuzzer-5087440458481664
Fixes: signed integer overflow: 3 + 2147483647 cannot be represented in type 'int'

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