]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Update constraint Rigid to work correctly with incorrect data
authorazv <azv@opencascade.com>
Wed, 8 Apr 2015 10:33:08 +0000 (13:33 +0300)
committerazv <azv@opencascade.com>
Wed, 8 Apr 2015 10:33:33 +0000 (13:33 +0300)
src/SketchSolver/SketchSolver_ConstraintRigid.cpp

index a1deb96ccd44516b25004ebf166363b615ae6554..6c1875ccb062394d2df1312fad8271c1aeb43626 100644 (file)
@@ -117,6 +117,11 @@ void SketchSolver_ConstraintRigid::getAttributes(
       myFeatureMap[myBaseFeature] = anEntityID;
   }
 
+  if (anEntityID == SLVS_E_UNKNOWN) {
+    myErrorMsg = SketchSolver_Error::NOT_INITIALIZED();
+    return;
+  }
+
   // Check the entity is complex
   Slvs_Entity anEntity = myStorage->getEntity(anEntityID);
   if (anEntity.point[0] != SLVS_E_UNKNOWN) {