PD: Fixes issue #14598: FreeCAD crashes on Undo

This commit is contained in:
wmayer
2024-06-14 14:02:57 +02:00
committed by Chris Hennes
parent 1041e74e69
commit 41b1fdcb84

View File

@@ -452,8 +452,10 @@ void ViewProviderBody::unifyVisualProperty(const App::Property* prop) {
}
//copy over the properties data
auto fprop = gdoc->getViewProvider(feature)->getPropertyByName(prop->getName());
fprop->Paste(*prop);
if (Gui::ViewProvider* vp = gdoc->getViewProvider(feature)) {
auto fprop = vp->getPropertyByName(prop->getName());
fprop->Paste(*prop);
}
}
}