Bug 562511 - comparison between signed and unsigned integer expressions in nsTextFragment::CopyTo, r=smaug

This commit is contained in:
timeless@mozdev.org 2010-04-28 16:56:00 -07:00
parent c803aa0b36
commit 9a72faf66f

View File

@ -272,7 +272,7 @@ nsTextFragment::CopyTo(PRUnichar *aDest, PRInt32 aOffset, PRInt32 aCount)
aOffset = 0; aOffset = 0;
} }
if (aOffset + aCount > GetLength()) { if (PRUint32(aOffset + aCount) > GetLength()) {
aCount = mState.mLength - aOffset; aCount = mState.mLength - aOffset;
} }