From 873158fd76f387142f5a5e6835052f4fd0ec6911 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Fri, 12 Feb 2016 03:40:19 +0100 Subject: [PATCH] avcodec/h264_slice: assert relation between current_slice ans slice_ctx Signed-off-by: Michael Niedermayer --- libavcodec/h264_slice.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libavcodec/h264_slice.c b/libavcodec/h264_slice.c index 6a80d894e1..8a335538a1 100644 --- a/libavcodec/h264_slice.c +++ b/libavcodec/h264_slice.c @@ -1212,6 +1212,9 @@ int ff_h264_decode_slice_header(H264Context *h, H264SliceContext *sl) } } + if (!h->current_slice) + av_assert0(sl == h->slice_ctx); + slice_type = get_ue_golomb_31(&sl->gb); if (slice_type > 9) { av_log(h->avctx, AV_LOG_ERROR,