[Part CheckGeometry] prevent crash when attempting to check origin axis

This commit is contained in:
mwganson
2024-09-28 19:17:52 -05:00
committed by Yorik van Havre
parent 4f98a27961
commit 54b669d9e8

View File

@@ -433,11 +433,16 @@ void TaskCheckGeometryResults::goCheck()
for(const auto &sel : selection) {
selectedCount++;
TopoDS_Shape shape = Part::Feature::getShape(sel.pObject,sel.SubName,true);
if (shape.IsNull())
if (shape.IsNull()) {
continue;
}
if (shape.Infinite()) {
continue;
}
currentSeparator = Gui::Application::Instance->getViewProvider(sel.pObject)->getRoot();
if (!currentSeparator)
if (!currentSeparator) {
continue;
}
QString baseName;
QTextStream baseStream(&baseName);
baseStream << sel.DocName;