]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/zmbv.c
cavsdec: check dimensions being valid.
[ffmpeg] / libavcodec / zmbv.c
index b7ebaf90fae4ab7e1b719698218ff1b92f120d1d..6ccee3985599ba41b1b3dfed0cb631302141ea4b 100644 (file)
@@ -505,7 +505,7 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
         c->decomp_size = 1;
     } else { // ZLIB-compressed data
         c->zstream.total_in = c->zstream.total_out = 0;
-        c->zstream.next_in = buf;
+        c->zstream.next_in = (uint8_t*)buf;
         c->zstream.avail_in = len;
         c->zstream.next_out = c->decomp_buf;
         c->zstream.avail_out = c->decomp_size;
@@ -673,7 +673,7 @@ static av_cold int decode_end(AVCodecContext *avctx)
 AVCodec ff_zmbv_decoder = {
     .name           = "zmbv",
     .type           = AVMEDIA_TYPE_VIDEO,
-    .id             = CODEC_ID_ZMBV,
+    .id             = AV_CODEC_ID_ZMBV,
     .priv_data_size = sizeof(ZmbvContext),
     .init           = decode_init,
     .close          = decode_end,