]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/tscc.c
Merge remote-tracking branch 'qatar/master'
[ffmpeg] / libavcodec / tscc.c
index dc344a100a90df3f3744fe7d98acd21dd4854e0f..bc57ec74cb01657dfd8703d97eff06b29227d676 100644 (file)
@@ -75,7 +75,6 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
     int buf_size = avpkt->size;
     CamtasiaContext * const c = avctx->priv_data;
     const unsigned char *encoded = buf;
-    unsigned char *outptr;
     int zret; // Zlib return code
     int len = buf_size;
 
@@ -89,8 +88,6 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
         return -1;
     }
 
-    outptr = c->pic.data[0]; // Output image pointer
-
     zret = inflateReset(&(c->zstream));
     if (zret != Z_OK) {
         av_log(avctx, AV_LOG_ERROR, "Inflate reset error: %d\n", zret);
@@ -145,6 +142,7 @@ static av_cold int decode_init(AVCodecContext *avctx)
 
     c->height = avctx->height;
 
+    avcodec_get_frame_defaults(&c->pic);
     // Needed if zlib unused or init aborted before inflateInit
     memset(&(c->zstream), 0, sizeof(z_stream));
     switch(avctx->bits_per_coded_sample){