X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavformat%2Fivfdec.c;h=3e1ea52cbf13b7ead5a7dccfec7d6ffae058b669;hb=29f5c1e51b0d156f4650b96ab56c07727fe9a9b7;hp=197c099bc3312f35cfb9edbcfd642ab718efe58c;hpb=ef71ef5f30ddf1cd61e46628a04608892caf76d2;p=ffmpeg diff --git a/libavformat/ivfdec.c b/libavformat/ivfdec.c index 197c099bc33..3e1ea52cbf1 100644 --- a/libavformat/ivfdec.c +++ b/libavformat/ivfdec.c @@ -23,7 +23,7 @@ #include "riff.h" #include "libavutil/intreadwrite.h" -static int probe(AVProbeData *p) +static int probe(const AVProbeData *p) { if (AV_RL32(p->buf) == MKTAG('D','K','I','F') && !AV_RL16(p->buf+4) && AV_RL16(p->buf+6) == 32) @@ -53,7 +53,8 @@ static int read_header(AVFormatContext *s) st->codecpar->height = avio_rl16(s->pb); time_base.den = avio_rl32(s->pb); time_base.num = avio_rl32(s->pb); - st->duration = avio_rl64(s->pb); + st->duration = avio_rl32(s->pb); + avio_skip(s->pb, 4); // unused st->need_parsing = AVSTREAM_PARSE_HEADERS; @@ -80,7 +81,7 @@ static int read_packet(AVFormatContext *s, AVPacket *pkt) return ret; } -AVInputFormat ff_ivf_demuxer = { +const AVInputFormat ff_ivf_demuxer = { .name = "ivf", .long_name = NULL_IF_CONFIG_SMALL("On2 IVF"), .read_probe = probe,