[matroska-devel] Bug in libebml found

John Cannon spyder482 at yahoo.com
Sun Apr 13 16:51:21 CEST 2003


Steve, I want your opinion on this.  I seem to have found a fix but I am not
quite sure if it's a valid way of doing it.  At the end of a file, the
filter would have an assertion failure.  The source of this problem is a
call to EbmlStream::SkipData() at line 988 of kaxdemux.cpp.  The actual
problem lies within the libebml code however.  As you know, the previously
mentioned method calls EbmlElement::SkipData() which has a severe problem in
it's code.  At line 435 of EbmlElement.cpp the variable bUpperElement is
never assigned thus creating an assertion failure when it reaches line 441.
The assertion lies within some other code but the value of bUpperElement is
random at all times in my debugging.  The fix that I found for it was to
change line 435 from:

int bUpperElement;

to:

int bUpperElement = 0;

I am not sure of the inner workings of libebml but this fixed the problem
for me as the assertion requires the value to be 0 and not a random number
like -8765357 :)

Spyder



http://www.matroska.org



More information about the Matroska-devel mailing list