зеркало из https://github.com/mozilla/pjs.git
46644: Fix FMM. Contribution from Daniel Bratell, bratell@lysator.liu.se, r=waterson and me
This commit is contained in:
Родитель
9c314b04e2
Коммит
4b6e16167f
|
@ -255,10 +255,10 @@ nsHTMLContentSinkStream::InitEncoders()
|
|||
void nsHTMLContentSinkStream::EnsureBufferSize(PRInt32 aNewSize)
|
||||
{
|
||||
if (mBufferSize < aNewSize) {
|
||||
if(mBuffer) delete [] mBuffer;
|
||||
if(mBuffer) nsMemory::Free(mBuffer);
|
||||
|
||||
mBufferSize = 2*aNewSize+1; // make this twice as large
|
||||
mBuffer = new char[mBufferSize];
|
||||
mBuffer = NS_STATIC_CAST(char *, nsMemory::Alloc(mBufferSize));
|
||||
if(mBuffer){
|
||||
mBuffer[0] = 0;
|
||||
}
|
||||
|
|
|
@ -255,10 +255,10 @@ nsHTMLContentSinkStream::InitEncoders()
|
|||
void nsHTMLContentSinkStream::EnsureBufferSize(PRInt32 aNewSize)
|
||||
{
|
||||
if (mBufferSize < aNewSize) {
|
||||
if(mBuffer) delete [] mBuffer;
|
||||
if(mBuffer) nsMemory::Free(mBuffer);
|
||||
|
||||
mBufferSize = 2*aNewSize+1; // make this twice as large
|
||||
mBuffer = new char[mBufferSize];
|
||||
mBuffer = NS_STATIC_CAST(char *, nsMemory::Alloc(mBufferSize));
|
||||
if(mBuffer){
|
||||
mBuffer[0] = 0;
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче