Mercurial > libavformat.hg
changeset 6030:fd82ce3c4e65 libavformat
matroskadec: Allow unknown EBML doctype
author | conrad |
---|---|
date | Sat, 22 May 2010 01:41:35 +0000 |
parents | 7e9deb9f0234 |
children | 02815f232ad3 |
files | matroskadec.c |
diffstat | 1 files changed, 3 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/matroskadec.c Sat May 22 01:41:32 2010 +0000 +++ b/matroskadec.c Sat May 22 01:41:35 2010 +0000 @@ -860,7 +860,8 @@ return AVPROBE_SCORE_MAX; } - return 0; + // probably valid EBML header but no recognized doctype + return AVPROBE_SCORE_MAX/2; } static MatroskaTrack *matroska_find_track_by_num(MatroskaDemuxContext *matroska, @@ -1157,9 +1158,7 @@ if (!strcmp(ebml.doctype, matroska_doctypes[i])) break; if (i >= FF_ARRAY_ELEMS(matroska_doctypes)) { - av_log(s, AV_LOG_ERROR, "Unknown EBML doctype '%s'\n", ebml.doctype); - ebml_free(ebml_syntax, &ebml); - return AVERROR_PATCHWELCOME; + av_log(s, AV_LOG_WARNING, "Unknown EBML doctype '%s'\n", ebml.doctype); } av_metadata_set2(&s->metadata, "doctype", ebml.doctype, 0); ebml_free(ebml_syntax, &ebml);