From 8fe547df94dd9295152b3937a65c299d6e41e8a7 Mon Sep 17 00:00:00 2001 From: Jolbas <39026960+Jolbas@users.noreply.github.com> Date: Mon, 10 Jun 2024 21:18:07 +0200 Subject: [PATCH] Part: Handle zero scale in TopoShape::_makeTransform With this commit the TopoShape::_makeTransform() use makeGTransform() if scale is zero to avoid crash. Fixes #14562 --- src/Mod/Part/App/TopoShape.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Mod/Part/App/TopoShape.cpp b/src/Mod/Part/App/TopoShape.cpp index 9db1b05622..23368de575 100644 --- a/src/Mod/Part/App/TopoShape.cpp +++ b/src/Mod/Part/App/TopoShape.cpp @@ -4198,7 +4198,8 @@ bool TopoShape::_makeTransform(const TopoShape &shape, if(checkScale) { try { auto type = rclTrf.hasScale(); - if (type != Base::ScaleType::Uniform && type != Base::ScaleType::NoScaling) { + if ((type != Base::ScaleType::Uniform && type != Base::ScaleType::NoScaling) + || (type == Base::ScaleType::Uniform && rclTrf.determinant3() == 0.0)) { makeGTransform(shape,rclTrf,op,copy); return true; }