detect EOF when reading the element size, similar to when reading the element id
This commit is contained in:
parent
8427995f27
commit
642c3c4e27
@ -417,7 +417,10 @@ EbmlElement * EbmlElement::FindNextElement(IOCallback & DataStream, const EbmlSe
|
||||
bFound = false;
|
||||
break;
|
||||
}
|
||||
ReadSize += DataStream.read(&PossibleIdNSize[SizeIdx++], 1);
|
||||
if( DataStream.read( &PossibleIdNSize[SizeIdx++], 1 ) == 0 ) {
|
||||
return NULL; // no more data ?
|
||||
}
|
||||
ReadSize++;
|
||||
PossibleSizeLength++;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user