diff options
author | Dale Curtis <dalecurtis@chromium.org> | 2014-01-02 14:29:38 -0800 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-01-07 03:05:30 +0100 |
commit | dcf0f82d08e88ea952aa97c16e4e774ce6c2ceb8 (patch) | |
tree | e9e9b80733d5c2f5e7bb295d4bbd890bab84bebf | |
parent | 061e94815322a0702977491158c0b5cbaca3ccc4 (diff) | |
download | ffmpeg-dcf0f82d08e88ea952aa97c16e4e774ce6c2ceb8.tar.gz |
h264: Clear ERContext.cur_pic when unref'ing current picture.
Signed-off-by: Dale Curtis <dalecurtis@chromium.org>
(cherry picked from commit 4feca2214a0b69dcbe4d1c7cd145c3881459e867)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavcodec/h264.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c index f044a58a97..1b531f560b 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -1957,6 +1957,10 @@ static int h264_frame_start(H264Context *h) h->cur_pic_ptr = pic; unref_picture(h, &h->cur_pic); + if (CONFIG_ERROR_RESILIENCE) { + h->er.cur_pic = NULL; + } + if ((ret = ref_picture(h, &h->cur_pic, h->cur_pic_ptr)) < 0) return ret; |