diff options
author | Alex Converse <alex.converse@gmail.com> | 2011-10-25 18:37:24 -0700 |
---|---|---|
committer | Alex Converse <alex.converse@gmail.com> | 2011-10-28 15:44:10 -0700 |
commit | 61856d06eb30955290911140e6745bad93a25323 (patch) | |
tree | 7c485705ad2c4ae45104d2ba5deeb0d832115d21 /libavformat | |
parent | 7a773d4d59c9a2e14cb84201f8d17cbf3edaede8 (diff) | |
download | ffmpeg-61856d06eb30955290911140e6745bad93a25323.tar.gz |
probe: Restore identification of files with very large id3 tags and no extension.
Restore behavior of identifying files with huge id3 tags as
mp3 at AVPROBE_SCORE_MAX/4. This was broken in r25378 and subsequently
removed in r25929.
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/utils.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c index 20be871669..81eee97a84 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -347,6 +347,14 @@ AVInputFormat *av_probe_input_format2(AVProbeData *pd, int is_opened, int *score } } + if (!fmt && id3 && *score_max < AVPROBE_SCORE_MAX/4-1) { + while ((fmt = av_iformat_next(fmt))) + if (fmt->extensions && av_match_ext("mp3", fmt->extensions)) { + *score_max = AVPROBE_SCORE_MAX/4-1; + break; + } + } + return fmt; } |