]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/vp8_parser.c
avcodec: Constify all the AVCodecParsers
[ffmpeg] / libavcodec / vp8_parser.c
index 609f5077d1a1b2add1dd3e13f0508615428dafa0..98b752bfb9d78d24d1452ff9c80f89aa95e08fc1 100644 (file)
@@ -28,6 +28,9 @@ static int parse(AVCodecParserContext *s,
     unsigned int frame_type;
     unsigned int profile;
 
+    *poutbuf      = buf;
+    *poutbuf_size = buf_size;
+
     if (buf_size < 3)
         return buf_size;
 
@@ -67,12 +70,10 @@ static int parse(AVCodecParserContext *s,
         s->coded_height = FFALIGN(height, 16);
     }
 
-    *poutbuf      = buf;
-    *poutbuf_size = buf_size;
     return buf_size;
 }
 
-AVCodecParser ff_vp8_parser = {
+const AVCodecParser ff_vp8_parser = {
     .codec_ids    = { AV_CODEC_ID_VP8 },
     .parser_parse = parse,
 };