]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/md5enc.c
avformat/thp: fix variable types to avoid overflows
[ffmpeg] / libavformat / md5enc.c
index 270d9fb660f0838e5888b4342dd7ae901881a4f0..8b14fbaa0f0ab545310068e4fc2d592f999b57db 100644 (file)
@@ -117,7 +117,12 @@ static int framemd5_write_header(struct AVFormatContext *s)
     int res = av_hash_alloc(&c->hash, c->hash_name);
     if (res < 0)
         return res;
-    return ff_framehash_write_header(s);
+    avio_printf(s->pb, "#format: frame checksums\n");
+    avio_printf(s->pb, "#version: 1\n");
+    avio_printf(s->pb, "#hash: %s\n", av_hash_get_name(c->hash));
+    ff_framehash_write_header(s);
+    avio_printf(s->pb, "#stream#, dts,        pts, duration,     size, hash\n");
+    return 0;
 }
 
 static int framemd5_write_packet(struct AVFormatContext *s, AVPacket *pkt)