]> git.sesse.net Git - ffmpeg/commitdiff
avformat/yuv4mpegenc: Add const where appropriate
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Fri, 4 Sep 2020 10:46:09 +0000 (12:46 +0200)
committerAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Fri, 4 Sep 2020 15:34:44 +0000 (17:34 +0200)
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
libavformat/yuv4mpegenc.c

index fdd020e13b0e2b5f11885d998ad2abf26185a0c5..6b53780ba06a5ceaf46b45613b5103c16f012903 100644 (file)
@@ -184,12 +184,10 @@ static int yuv4_write_packet(AVFormatContext *s, AVPacket *pkt)
 {
     AVStream *st = s->streams[pkt->stream_index];
     AVIOContext *pb = s->pb;
-    AVFrame *frame;
+    const AVFrame *frame = (const AVFrame *)pkt->data;
     int width, height, h_chroma_shift, v_chroma_shift;
     int i;
-    uint8_t *ptr, *ptr1, *ptr2;
-
-    frame = (AVFrame *)pkt->data;
+    const uint8_t *ptr, *ptr1, *ptr2;
 
     /* construct frame header */