]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/xxan.c
Merge remote-tracking branch 'qatar/master'
[ffmpeg] / libavcodec / xxan.c
index 56d5f4961dcb5051625e76afcad1f6efb23c9068..b261cdfdec988c67ef4b6dc8e11e43e7bed67ef3 100644 (file)
@@ -38,7 +38,17 @@ typedef struct XanContext {
     GetByteContext gb;
 } XanContext;
 
-static av_cold int xan_decode_end(AVCodecContext *avctx);
+static av_cold int xan_decode_end(AVCodecContext *avctx)
+{
+    XanContext *s = avctx->priv_data;
+
+    av_frame_free(&s->pic);
+
+    av_freep(&s->y_buffer);
+    av_freep(&s->scratch_buffer);
+
+    return 0;
+}
 
 static av_cold int xan_decode_init(AVCodecContext *avctx)
 {
@@ -428,18 +438,6 @@ static int xan_decode_frame(AVCodecContext *avctx,
     return avpkt->size;
 }
 
-static av_cold int xan_decode_end(AVCodecContext *avctx)
-{
-    XanContext *s = avctx->priv_data;
-
-    av_frame_free(&s->pic);
-
-    av_freep(&s->y_buffer);
-    av_freep(&s->scratch_buffer);
-
-    return 0;
-}
-
 AVCodec ff_xan_wc4_decoder = {
     .name           = "xan_wc4",
     .long_name      = NULL_IF_CONFIG_SMALL("Wing Commander IV / Xxan"),