]> SALOME platform Git repositories - modules/shaper.git/blobdiff - src/FeaturesPlugin/FeaturesPlugin_Validators.cpp
Salome HOME
Issue #2645: SIGSEGV when creating a fillet
[modules/shaper.git] / src / FeaturesPlugin / FeaturesPlugin_Validators.cpp
index e28008720d77cdd77dfd50a16a017ec601163cda..b991e38f0b58914f2463c27ba09d21f9d4d5d4b9 100644 (file)
@@ -716,6 +716,11 @@ bool FeaturesPlugin_ValidatorFilletSelection::isValid(const AttributePtr& theAtt
     ResultBodyPtr aContextOwner = ModelAPI_Tools::bodyOwner(aContext);
     GeomShapePtr anOwner = aContextOwner.get() ? aContextOwner->shape() : aContext->shape();
 
+    if (!anOwner) {
+      theError = "Error: wrong feature is selected.";
+      return false;
+    }
+
     if (anOwner->shapeType() != GeomAPI_Shape::SOLID &&
         anOwner->shapeType() != GeomAPI_Shape::COMPSOLID) {
       theError = "Error: Not all selected shapes are sub-shapes of solids.";