aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-03-09 12:11:40 +0100
committerMichael Niedermayer <michaelni@gmx.at>2015-03-09 12:11:40 +0100
commitb837d5bf83f982410fd94f6a2aaa24c29e5e770f (patch)
treec5a30f3ae6bc8968e2a9f12bdb1e64e5bac075f0
parent36cfee3adc70c6a78a07df4bb16349c4b0893ef4 (diff)
parent03fbb6ff3d28f639ea5a35aba3c6dca09c17225d (diff)
downloadffmpeg-b837d5bf83f982410fd94f6a2aaa24c29e5e770f.tar.gz
Merge commit '03fbb6ff3d28f639ea5a35aba3c6dca09c17225d' into release/2.2
* commit '03fbb6ff3d28f639ea5a35aba3c6dca09c17225d': h264: only ref cur_pic in update_thread_context if it is initialized Conflicts: libavcodec/h264.c See: 0fc01ae33c7712168aab0f98c5715b40da0b5f03 Merged-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavcodec/h264.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c
index ab86fac06d..dc56c56242 100644
--- a/libavcodec/h264.c
+++ b/libavcodec/h264.c
@@ -1884,8 +1884,11 @@ static int decode_update_thread_context(AVCodecContext *dst,
h->cur_pic_ptr = REBASE_PICTURE(h1->cur_pic_ptr, h, h1);
unref_picture(h, &h->cur_pic);
- if (h1->cur_pic.f.buf[0] && (ret = ref_picture(h, &h->cur_pic, &h1->cur_pic)) < 0)
- return ret;
+ if (h1->cur_pic.f.buf[0]) {
+ ret = ref_picture(h, &h->cur_pic, &h1->cur_pic);
+ if (ret < 0)
+ return ret;
+ }
h->workaround_bugs = h1->workaround_bugs;
h->low_delay = h1->low_delay;