From: nds Date: Sat, 26 Dec 2015 18:16:36 +0000 (+0300) Subject: Crash in solver in the following case: X-Git-Tag: V_2.1.0~18 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=fc88c49ff45f48d63ff6067384e56eb146c4cbc0;p=modules%2Fshaper.git Crash in solver in the following case: 1. Start sketch 2. Create a line 3. Start Fixed constraint 4. Select a point on the line. Apply 5. Select the line by rectangle 6. Delete button click BUG: crash --- diff --git a/src/SketchSolver/SketchSolver_ConstraintFixed.cpp b/src/SketchSolver/SketchSolver_ConstraintFixed.cpp index 012a45423..ee1700d22 100644 --- a/src/SketchSolver/SketchSolver_ConstraintFixed.cpp +++ b/src/SketchSolver/SketchSolver_ConstraintFixed.cpp @@ -100,8 +100,10 @@ bool SketchSolver_ConstraintFixed::remove() if (myBaseConstraint && myFixedAttribute) { if (myFixedAttribute->isObject()) aFeature = ModelAPI_Feature::feature(myFixedAttribute->object()); - else - myStorage->update(AttributePtr(myFixedAttribute), myGroupID); + else { + if (myFixedAttribute->attr().get()) + myStorage->update(AttributePtr(myFixedAttribute), myGroupID); + } } if (aFeature) myStorage->update(aFeature, myGroupID);