X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavformat%2Fmicrodvddec.c;h=ca9086afe9bb4c535993feef6330c727db0653f1;hb=fe7fbf3a2273b2f13c3190fcda58b9663b535157;hp=c2f1ac45cda7a029ef45c7315566ff2e514ee565;hpb=b8eb0827f053230dd919bc73e25381b47b4fe1a7;p=ffmpeg diff --git a/libavformat/microdvddec.c b/libavformat/microdvddec.c index c2f1ac45cda..ca9086afe9b 100644 --- a/libavformat/microdvddec.c +++ b/libavformat/microdvddec.c @@ -36,7 +36,7 @@ typedef struct { } MicroDVDContext; -static int microdvd_probe(AVProbeData *p) +static int microdvd_probe(const AVProbeData *p) { unsigned char c; const uint8_t *ptr = p->buf; @@ -102,6 +102,8 @@ static int microdvd_read_header(AVFormatContext *s) if (!len) break; line[strcspn(line, "\r\n")] = 0; + if (!*p) + continue; if (i++ < 3) { int frame; double fps;