Commit b3e5f15b authored by Kieran Kunhya's avatar Kieran Kunhya Committed by Michael Niedermayer

opusdec: Don't run vector_fmul_scalar on zero length arrays

Fixes crashes on fuzzed files
Fixes Ticket4969 part2
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 07225fa7
......@@ -585,7 +585,7 @@ static int opus_decode_packet(AVCodecContext *avctx, void *data,
memset(frame->extended_data[i], 0, frame->linesize[0]);
}
if (c->gain_i) {
if (c->gain_i && decoded_samples > 0) {
c->fdsp->vector_fmul_scalar((float*)frame->extended_data[i],
(float*)frame->extended_data[i],
c->gain, FFALIGN(decoded_samples, 8));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment