Fixes: left shift of negative value -1
Fixes: 30714/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_CFHD_fuzzer-4867823371419648
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
const uint16_t q = s->quantisation;
for (i = 0; i < run; i++) {
- *coeff_data |= coeff << 8;
+ *coeff_data |= coeff * 256;
*coeff_data++ *= q;
}
} else {
const uint16_t q = s->quantisation;
for (i = 0; i < run; i++) {
- *coeff_data |= coeff << 8;
+ *coeff_data |= coeff * 256;
*coeff_data++ *= q;
}
} else {