matroska: fix a corner case in ebml-lace parsing
authorLuca Barbato <lu_zero@gentoo.org>
Thu, 28 Mar 2013 10:52:52 +0000 (11:52 +0100)
committerLuca Barbato <lu_zero@gentoo.org>
Wed, 3 Apr 2013 10:33:15 +0000 (12:33 +0200)
Make sure we notice when the lace_size[n] is a negative value.

CC: libav-stable@libav.org
libavformat/matroskadec.c

index 2ec669f..67a3308 100644 (file)
@@ -1820,7 +1820,7 @@ static int matroska_parse_laces(MatroskaDemuxContext *matroska, uint8_t **buf,
 
     case 0x3: /* EBML lacing */ {
         uint64_t num;
-        uint32_t total;
+        uint64_t total;
         n = matroska_ebmlnum_uint(matroska, data, size, &num);
         if (n < 0) {
             av_log(matroska->ctx, AV_LOG_INFO,