h264: Make sure reinit failures mark the context as not initialized
authorLuca Barbato <lu_zero@gentoo.org>
Mon, 25 May 2015 20:30:10 +0000 (22:30 +0200)
committerMichael Niedermayer <michael@niedermayer.cc>
Mon, 20 Jul 2015 02:43:39 +0000 (04:43 +0200)
(cherry picked from commit 0181ae9af2de1526464d23209b82e6674d362f5d)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/h264_slice.c

index d8b7bc7..b3fdc99 100644 (file)
@@ -1454,6 +1454,7 @@ int ff_h264_decode_slice_header(H264Context *h, H264Context *h0)
 
     if (h->context_initialized &&
         (must_reinit || needs_reinit)) {
+        h->context_initialized = 0;
         if (h != h0) {
             av_log(h->avctx, AV_LOG_ERROR,
                    "changing width %d -> %d / height %d -> %d on "