From 8710ee11d75eebc17e7d63bc6ffb91766933bd68 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Thu, 3 Apr 2014 23:46:25 +0200 Subject: avcodec/h264: clear cur_pic structure instead of duplicating it in ff_h264_update_thread_context() Fixes crash Found-by: iive Signed-off-by: Michael Niedermayer --- libavcodec/h264_slice.c | 1 + 1 file changed, 1 insertion(+) (limited to 'libavcodec') diff --git a/libavcodec/h264_slice.c b/libavcodec/h264_slice.c index ed3c8fe35d..17557d1538 100644 --- a/libavcodec/h264_slice.c +++ b/libavcodec/h264_slice.c @@ -576,6 +576,7 @@ int ff_h264_update_thread_context(AVCodecContext *dst, memset(&h->mb, 0, sizeof(h->mb)); memset(&h->mb_luma_dc, 0, sizeof(h->mb_luma_dc)); memset(&h->mb_padding, 0, sizeof(h->mb_padding)); + memset(&h->cur_pic, 0, sizeof(h->cur_pic)); h->avctx = dst; h->DPB = NULL; -- cgit v1.2.1