vc1dec: raise an error if sprite picture data is missing
authorSean McGovern <gseanmcg@gmail.com>
Sat, 22 Apr 2017 23:16:34 +0000 (19:16 -0400)
committerSean McGovern <gseanmcg@gmail.com>
Mon, 24 Apr 2017 22:28:55 +0000 (18:28 -0400)
Bug-Id: 1013
CC: libav-stable@libav.org
libavcodec/vc1dec.c

index 89b4f4b..51745c1 100644 (file)
@@ -270,7 +270,7 @@ static int vc1_decode_sprites(VC1Context *v, GetBitContext* gb)
 
     vc1_parse_sprites(v, gb, &sd);
 
-    if (!s->current_picture.f->data[0]) {
+    if (!s->current_picture.f || !s->current_picture.f->data[0]) {
         av_log(avctx, AV_LOG_ERROR, "Got no sprites\n");
         return -1;
     }