# HG changeset patch # User michael # Date 1186761978 0 # Node ID 76827ffd1cf6f8dcdb0d8589037301a5bbe2a537 # Parent 7c31128b23f83ef37107fa2d0d5761701c4fa5d1 flac probe closes issue83 diff -r 7c31128b23f8 -r 76827ffd1cf6 raw.c --- a/raw.c Fri Aug 10 15:37:55 2007 +0000 +++ b/raw.c Fri Aug 10 16:06:18 2007 +0000 @@ -434,6 +434,12 @@ else return 0; } +static int flac_probe(AVProbeData *p) +{ + if(memcmp(p->buf, "fLaC", 4)) return 0; + else AVPROBE_SCORE_MAX / 2; +} + AVInputFormat shorten_demuxer = { "shn", "raw shorten", @@ -450,7 +456,7 @@ "flac", "raw flac", 0, - NULL, + flac_probe, flac_read_header, raw_read_partial_packet, raw_read_close,