X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavformat%2Fhcom.c;h=0d1736b6201ab95b5d77dbf773ffd2752d3accb8;hb=d6489ddb7a6cdfb6bd4e5b8095d765e0ba1aba4a;hp=933ecce373ca8312f3fc1b16d820d7352790585c;hpb=268d1466498b0f404719b21f3b78802820b6881b;p=ffmpeg diff --git a/libavformat/hcom.c b/libavformat/hcom.c index 933ecce373c..0d1736b6201 100644 --- a/libavformat/hcom.c +++ b/libavformat/hcom.c @@ -25,8 +25,10 @@ #include "internal.h" #include "pcm.h" -static int hcom_probe(AVProbeData *p) +static int hcom_probe(const AVProbeData *p) { + if (p->buf_size < 132) + return 0; if (!memcmp(p->buf+65, "FSSD", 4) && !memcmp(p->buf+128, "HCOM", 4)) return AVPROBE_SCORE_MAX;