[FFmpeg-cvslog] r23591 - trunk/libavformat/matroskadec.c

aurel subversion
Fri Jun 11 19:16:44 CEST 2010


Author: aurel
Date: Fri Jun 11 19:16:43 2010
New Revision: 23591

Log:
matroskadec: fix type of the length field in ebml_read_master()
Also use the correct value for unknown size (instead of a truncated
and sign extended value).

Modified:
   trunk/libavformat/matroskadec.c

Modified: trunk/libavformat/matroskadec.c
==============================================================================
--- trunk/libavformat/matroskadec.c	Fri Jun 11 18:45:38 2010	(r23590)
+++ trunk/libavformat/matroskadec.c	Fri Jun 11 19:16:43 2010	(r23591)
@@ -657,7 +657,7 @@ static int ebml_read_binary(ByteIOContex
  * are supposed to be sub-elements which can be read separately.
  * 0 is success, < 0 is failure.
  */
-static int ebml_read_master(MatroskaDemuxContext *matroska, int length)
+static int ebml_read_master(MatroskaDemuxContext *matroska, uint64_t length)
 {
     ByteIOContext *pb = matroska->ctx->pb;
     MatroskaLevel *level;
@@ -718,7 +718,7 @@ static int ebml_parse_id(MatroskaDemuxCo
             break;
     if (!syntax[i].id && id == MATROSKA_ID_CLUSTER &&
         matroska->num_levels > 0 &&
-        matroska->levels[matroska->num_levels-1].length == 0xffffffffffffffff)
+        matroska->levels[matroska->num_levels-1].length == 0xffffffffffffff)
         return 0;  // we reached the end of an unknown size cluster
     if (!syntax[i].id && id != EBML_ID_VOID && id != EBML_ID_CRC32)
         av_log(matroska->ctx, AV_LOG_INFO, "Unknown entry 0x%X\n", id);



More information about the ffmpeg-cvslog mailing list