mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-23 10:15:41 +00:00
Bug 1238777: Bail early from ComputeSnappedImageDrawingParameters if we're somehow drawing from a 0-sized subimage. r=tn
This commit is contained in:
parent
2712f6a1e1
commit
2c0dc8a8a0
@ -6229,6 +6229,11 @@ ComputeSnappedImageDrawingParameters(gfxContext* aCtx,
|
||||
subimage.SizeTo(NSToIntCeil(subimageBottomRight.x) - subimage.x,
|
||||
NSToIntCeil(subimageBottomRight.y) - subimage.y);
|
||||
|
||||
if (subimage.IsEmpty()) {
|
||||
// Bail if the subimage is empty (we're not going to be drawing anything).
|
||||
return SnappedImageDrawingParameters();
|
||||
}
|
||||
|
||||
gfxMatrix transform;
|
||||
gfxMatrix invTransform;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user