Bug 411874 - "Crash [@ ffff068b nsGIFDecoder2::EndImageFrame] while loading MySpace page (hard to repro)" [p=alfredkayser@gmail.com (Alfred Kayser) r=stuart a1.9=schrep]

git-svn-id: svn://10.0.0.236/trunk@243528 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
reed%reedloden.com
2008-01-19 07:00:24 +00:00
parent 78e385217b
commit 6da7445762

View File

@@ -395,7 +395,7 @@ void nsGIFDecoder2::EndImageFrame()
if (mGIFStruct.rows_remaining != mGIFStruct.height) {
if (mGIFStruct.rows_remaining && mGIFStruct.images_decoded) {
// Clear the remaining rows (only needed for the animation frames)
PRUint8 *rowp = mImageData + ((mGIFStruct.rows_remaining - mGIFStruct.height) * mGIFStruct.width);
PRUint8 *rowp = mImageData + ((mGIFStruct.height - mGIFStruct.rows_remaining) * mGIFStruct.width);
memset(rowp, 0, mGIFStruct.rows_remaining * mGIFStruct.width);
}