Message ID | 20240326023056.20548-3-michael@niedermayer.cc |
---|---|
State | Accepted |
Commit | 7eabe564365f4130c4d8f1d50fd835b45dc46355 |
Headers | show |
Series | [FFmpeg-devel,1/7] avcodec/hcadec: do not set hfr_group_count to invalid values | expand |
Context | Check | Description |
---|---|---|
yinshiyou/make_loongarch64 | success | Make finished |
yinshiyou/make_fate_loongarch64 | success | Make fate finished |
andriy/make_x86 | success | Make finished |
andriy/make_fate_x86 | success | Make fate finished |
diff --git a/libavcodec/qoadec.c b/libavcodec/qoadec.c index 75099d1199f..c5cf351f9c1 100644 --- a/libavcodec/qoadec.c +++ b/libavcodec/qoadec.c @@ -67,7 +67,7 @@ static int qoa_lms_predict(QOAChannel *lms) { int prediction = 0; for (int i = 0; i < QOA_LMS_LEN; i++) - prediction += lms->weights[i] * lms->history[i]; + prediction += (unsigned)lms->weights[i] * lms->history[i]; return prediction >> 13; }
Fixes: signed integer overflow: -1575944192 + -602931200 cannot be represented in type 'int' Fixes: 62285/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_QOA_fuzzer-6470469339185152 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> --- libavcodec/qoadec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)