avformat/mov: zero initialize codec_name in mov_parse_stsd_video()
authorJames Almer <jamrial@gmail.com>
Sat, 12 Nov 2016 23:52:22 +0000 (20:52 -0300)
committerJames Almer <jamrial@gmail.com>
Sat, 12 Nov 2016 23:52:22 +0000 (20:52 -0300)
Fixes valgrind warning about "Conditional jump or move depends on uninitialised value(s)"

Reviewed-by: Andreas Cadhalpun <andreas.cadhalpun@googlemail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
libavformat/mov.c

index 9ec7d03..17d63d6 100644 (file)
@@ -1832,7 +1832,7 @@ static int mov_codec_id(AVStream *st, uint32_t format)
 static void mov_parse_stsd_video(MOVContext *c, AVIOContext *pb,
                                  AVStream *st, MOVStreamContext *sc)
 {
-    uint8_t codec_name[32];
+    uint8_t codec_name[32] = { 0 };
     int64_t stsd_start;
     unsigned int len;