Salome HOME
Avoid crash if there is no parent of selection attribute.
[modules/shaper.git] / src / GeomAPI / GeomAPI_Tools.cpp
index 0825957681036ae6d31270139c4cd882d46b6512..c15700df1cbc68621f0320f5efe17ae32116bc34 100644 (file)
@@ -28,6 +28,9 @@
 //==================================================================================================
 GeomShapePtr GeomAPI_Tools::getTypedShape(const GeomShapePtr& theShape)
 {
+  if (!theShape.get())
+    return GeomShapePtr();
+
   GeomShapePtr aTypedShape = theShape;
 
   GeomAPI_Shape::ShapeType aType = theShape->shapeType();