Do a bounds check before trying to find the mid.

CCMAIL:Felix Hupfeld <hupfeld@zib.de>


git-svn-id: svn://anonsvn.kde.org/home/kde/trunk/kdesupport/taglib@415196 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
This commit is contained in:
Scott Wheeler 2005-05-17 20:45:05 +00:00
parent 7e325a26aa
commit fc8c7d357b

View File

@ -344,6 +344,9 @@ ByteVector ByteVector::mid(uint index, uint length) const
{
ByteVector v;
if(index > size())
return v;
ConstIterator endIt;
if(length < 0xffffffff && length + index < size())