Commit 1db8bc56 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/fic: clear slice_data

Fixes artifacts
Fixes use of freed memory
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent d46ef401
......@@ -212,6 +212,7 @@ static int fic_decode_frame(AVCodecContext *avctx, void *data,
av_log(avctx, AV_LOG_ERROR, "Could not allocate slice data.\n");
return AVERROR(ENOMEM);
}
memset(ctx->slice_data, 0, nslices * sizeof(ctx->slice_data[0]));
for (slice = 0; slice < nslices; slice++) {
unsigned slice_off = AV_RB32(src + tsize + FIC_HEADER_SIZE + slice * 4);
......
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