Bug 996745: Do not try to FinalizeFrame when there is no buffer. r=mattwoodrow

This commit is contained in:
Bas Schouten 2014-04-29 22:33:11 +02:00
parent 821065aa60
commit 4b872abb0d

View File

@ -516,10 +516,12 @@ RotatedContentBuffer::BeginPaint(ThebesLayer* aLayer,
if (result.mRegionToDraw.IsEmpty())
return result;
// Do not modify result.mRegionToDraw or result.mContentType after this call.
// Do not modify mBufferRect, mBufferRotation, or mDidSelfCopy,
// or call CreateBuffer before this call.
FinalizeFrame(result.mRegionToDraw);
if (HaveBuffer()) {
// Do not modify result.mRegionToDraw or result.mContentType after this call.
// Do not modify mBufferRect, mBufferRotation, or mDidSelfCopy,
// or call CreateBuffer before this call.
FinalizeFrame(result.mRegionToDraw);
}
nsIntRect drawBounds = result.mRegionToDraw.GetBounds();
RefPtr<DrawTarget> destDTBuffer;