int avflag;
} BFIContext;
-static int bfi_probe(AVProbeData * p)
+static int bfi_probe(const AVProbeData * p)
{
/* Check file header */
if (AV_RL32(p->buf) == MKTAG('B', 'F', '&', 'I'))
/* Set the total number of frames. */
avio_skip(pb, 8);
chunk_header = avio_rl32(pb);
+ if (chunk_header < 3)
+ return AVERROR_INVALIDDATA;
+
bfi->nframes = avio_rl32(pb);
avio_rl32(pb);
avio_rl32(pb);
return ret;
}
-AVInputFormat ff_bfi_demuxer = {
+const AVInputFormat ff_bfi_demuxer = {
.name = "bfi",
.long_name = NULL_IF_CONFIG_SMALL("Brute Force & Ignorance"),
.priv_data_size = sizeof(BFIContext),