avcodec/cfhd: fix overflow in multiplication in LUT calculation

This commit is contained in:
Paul B Mahol 2020-08-04 08:20:36 +02:00
parent 9c0beaf0d3
commit 6ce4338943

View File

@ -65,7 +65,7 @@ static av_cold int cfhd_init(AVCodecContext *avctx)
}
for (int i = 0; i < 256; i++)
s->lut[1][i] = i + ((768 * i * i * i) / (256 * 256 * 256));
s->lut[1][i] = i + ((768LL * i * i * i) / (256 * 256 * 256));
return ff_cfhd_init_vlcs(s);
}