[FFmpeg-cvslog] matroskadec: Fix null pointer exception on corrupted input.

Michael Niedermayer git at videolan.org
Fri Mar 16 06:21:50 CET 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Fri Mar 16 05:28:18 2012 +0100| [d9fe6b926cd619c311e45e0ae352cf09713c482c] | committer: Michael Niedermayer

matroskadec: Fix null pointer exception on corrupted input.

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=d9fe6b926cd619c311e45e0ae352cf09713c482c
---

 libavformat/matroskadec.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c
index d3f6a3e..dbe2815 100644
--- a/libavformat/matroskadec.c
+++ b/libavformat/matroskadec.c
@@ -1377,7 +1377,7 @@ static int matroska_read_header(AVFormatContext *s)
     /* First read the EBML header. */
     if (ebml_parse(matroska, ebml_syntax, &ebml)
         || ebml.version > EBML_VERSION       || ebml.max_size > sizeof(uint64_t)
-        || ebml.id_length > sizeof(uint32_t) || ebml.doctype_version > 3) {
+        || ebml.id_length > sizeof(uint32_t) || ebml.doctype_version > 3 || !ebml.doctype) {
         av_log(matroska->ctx, AV_LOG_ERROR,
                "EBML header using unsupported features\n"
                "(EBML version %"PRIu64", doctype %s, doc version %"PRIu64")\n",



More information about the ffmpeg-cvslog mailing list