Module: libav Branch: master Commit: a8a45dfe25ec63f23676258a11e57b312a794d4c
Author: Diego Biurrun <[email protected]> Committer: Diego Biurrun <[email protected]> Date: Mon Mar 25 16:14:55 2013 +0100 avs: Increase magic value score above file extension score This should fix misdetection of AVS files as AviSynth scripts when AviSynth support is enabled (Bugzilla #357). --- libavformat/avs.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/libavformat/avs.c b/libavformat/avs.c index b96a122..3e95a36 100644 --- a/libavformat/avs.c +++ b/libavformat/avs.c @@ -50,7 +50,9 @@ static int avs_probe(AVProbeData * p) d = p->buf; if (d[0] == 'w' && d[1] == 'W' && d[2] == 0x10 && d[3] == 0) - return AVPROBE_SCORE_EXTENSION; + /* Ensure the buffer probe scores higher than the extension probe. + * This avoids problems with misdetection as AviSynth scripts. */ + return AVPROBE_SCORE_EXTENSION + 1; return 0; } _______________________________________________ libav-commits mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-commits
