Commit e3f656f2 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/ac3dec: Fix null pointer dereference in ac3_decode_frame()

Fixes: index 8 out of bounds for type 'uint8_t *[8]'
Fixes: 7273/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_EAC3_fuzzer-6296497667702784

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpegSigned-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 90475db9
......@@ -1738,7 +1738,9 @@ dependent_frame:
for (ch = 0; ch < avctx->channels; ch++) {
int map = extended_channel_map[ch];
memcpy((SHORTFLOAT *)frame->data[ch], s->output_buffer[map],
av_assert0(ch>=AV_NUM_DATA_POINTERS || frame->extended_data[ch] == frame->data[ch]);
memcpy((SHORTFLOAT *)frame->extended_data[ch],
s->output_buffer[map],
s->num_blocks * AC3_BLOCK_SIZE * sizeof(SHORTFLOAT));
}
......
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