From c67d673d4f80bd22c8db2b5d691b4fde4d146ea0 Mon Sep 17 00:00:00 2001 From: wolfbeast Date: Wed, 14 Aug 2019 15:09:34 +0200 Subject: Issue #438: Check for non-rectilinear transforms --- layout/svg/nsSVGOuterSVGFrame.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'layout') diff --git a/layout/svg/nsSVGOuterSVGFrame.cpp b/layout/svg/nsSVGOuterSVGFrame.cpp index e1b97bb40..434676010 100644 --- a/layout/svg/nsSVGOuterSVGFrame.cpp +++ b/layout/svg/nsSVGOuterSVGFrame.cpp @@ -1006,6 +1006,9 @@ nsSVGOuterSVGAnonChildFrame::IsSVGTransformed(Matrix* aOwnTransform, if (ownMatrix.HasNonTranslation()) { // Note: viewBox, currentScale and currentTranslate should only // produce a rectilinear transform. + MOZ_ASSERT(ownMatrix.IsRectilinear(), + "Non-rectilinear transform will break the following logic"); + // The nsDisplayTransform code will apply this transform to our frame, // including to our frame position. We don't want our frame position to // be scaled though, so we need to correct for that in the transform. -- cgit v1.2.3