Bug 886730 - Move a szip.cpp MOZ_ASSERT to a safer place. r=nfroyd

This commit is contained in:
Mike Hommey 2013-06-27 09:35:49 +09:00
parent fc82c0f523
commit 071998d656

View File

@ -441,13 +441,13 @@ int SzipCompress::do_compress(Buffer &origBuf, Buffer &outBuf,
}
header->lastChunkSize = avail;
MOZ_ASSERT(header->totalSize == offset);
MOZ_ASSERT(header->nChunks == nChunks);
if (!outBuf.Resize(offset)) {
LOG("Error truncating output: %s", strerror(errno));
return 1;
}
MOZ_ASSERT(header->nChunks == nChunks);
return 0;
}