]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/intrax8.c
VP9 Profile 2 VDPAU support
[ffmpeg] / libavcodec / intrax8.c
index d46f97c7a4baaa2aaa5e84725c66cfe03fa951ee..f385423dc1f78414c0dedbabe8b9e94c0f216e45 100644 (file)
@@ -801,6 +801,8 @@ int ff_intrax8_decode_picture(IntraX8Context *w, Picture *pict,
     for (w->mb_y = 0; w->mb_y < w->mb_height * 2; w->mb_y++) {
         x8_init_block_index(w, w->frame);
         mb_xy = (w->mb_y >> 1) * (w->mb_width + 1);
+        if (get_bits_left(gb) < 1)
+            goto error;
         for (w->mb_x = 0; w->mb_x < w->mb_width * 2; w->mb_x++) {
             x8_get_prediction(w);
             if (x8_setup_spatial_predictor(w, 0))