Index: Source/core/rendering/svg/RenderSVGForeignObject.cpp |
diff --git a/Source/core/rendering/svg/RenderSVGForeignObject.cpp b/Source/core/rendering/svg/RenderSVGForeignObject.cpp |
index 7506b4626e33fb8ef57351126960f2ce051aca96..78a6caf1e5c0eb6dafd6d69a7370bedbf2c040f7 100644 |
--- a/Source/core/rendering/svg/RenderSVGForeignObject.cpp |
+++ b/Source/core/rendering/svg/RenderSVGForeignObject.cpp |
@@ -168,7 +168,11 @@ bool RenderSVGForeignObject::nodeAtFloatPoint(const HitTestRequest& request, Hit |
if (hitTestAction != HitTestForeground) |
return false; |
- FloatPoint localPoint = localTransform().inverse().mapPoint(pointInParent); |
+ AffineTransform localTransform = this->localTransform(); |
+ if (!localTransform.isInvertible()) |
+ return false; |
+ |
+ FloatPoint localPoint = localTransform.inverse().mapPoint(pointInParent); |
// Early exit if local point is not contained in clipped viewport area |
if (SVGRenderSupport::isOverflowHidden(this) && !m_viewport.contains(localPoint)) |