Assert that the context doesnt overflow in ffv1.
authorMichael Niedermayer <michaelni@gmx.at>
Thu, 14 Oct 2010 22:03:38 +0000 (22:03 +0000)
committerMichael Niedermayer <michaelni@gmx.at>
Thu, 14 Oct 2010 22:03:38 +0000 (22:03 +0000)
Originally committed as revision 25475 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavcodec/ffv1.c

index 87a2050..6691395 100644 (file)
@@ -1024,6 +1024,7 @@ static av_always_inline void decode_line(FFV1Context *s, int w, int_fast16_t *sa
         }else
             sign=0;
 
+        av_assert2(context < p->context_count);
 
         if(s->ac){
             diff= get_symbol_inline(c, p->state[context], 1);