From: azv Date: Thu, 2 Jun 2016 12:20:33 +0000 (+0300) Subject: Fix crash on tangent arc in SolveSpaceSolver X-Git-Tag: V_2.3.1~3 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=16f3db3dc0f2eefe54ce1452cfa476c2774c6ae9;p=modules%2Fshaper.git Fix crash on tangent arc in SolveSpaceSolver --- diff --git a/src/SketchSolver/SolveSpaceSolver/SolveSpaceSolver_Storage.cpp b/src/SketchSolver/SolveSpaceSolver/SolveSpaceSolver_Storage.cpp index e2c9f5d98..805e458dd 100644 --- a/src/SketchSolver/SolveSpaceSolver/SolveSpaceSolver_Storage.cpp +++ b/src/SketchSolver/SolveSpaceSolver/SolveSpaceSolver_Storage.cpp @@ -78,8 +78,9 @@ bool SolveSpaceSolver_Storage::update(ConstraintWrapperPtr theConstraint) isUpdated = update(*anIt) || isUpdated; // do not update constrained entities for Multi constraints, // and for middle point constraint translated to equal lines + ConstraintPtr aBaseConstraint = theConstraint->baseConstraint(); if (aSlvsConstr.type == SLVS_C_MULTI_ROTATION || aSlvsConstr.type == SLVS_C_MULTI_TRANSLATION || - (theConstraint->baseConstraint()->getKind() == SketchPlugin_ConstraintMiddle::ID() && + (aBaseConstraint && aBaseConstraint->getKind() == SketchPlugin_ConstraintMiddle::ID() && aSlvsConstr.type != SLVS_C_AT_MIDPOINT)) continue;