From: azv Date: Mon, 17 Aug 2015 12:40:20 +0000 (+0300) Subject: Avoid removing distance entity from list of SolveSpace entities (issue #848) X-Git-Tag: V_1.4.0_beta4~368 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=f175052b8079da90b68d1c8667e6d3fdf06548f4;p=modules%2Fshaper.git Avoid removing distance entity from list of SolveSpace entities (issue #848) --- diff --git a/src/SketchSolver/SketchSolver_Storage.cpp b/src/SketchSolver/SketchSolver_Storage.cpp index 2f2700fd2..a716b6859 100644 --- a/src/SketchSolver/SketchSolver_Storage.cpp +++ b/src/SketchSolver/SketchSolver_Storage.cpp @@ -215,8 +215,10 @@ void SketchSolver_Storage::removeUnusedEntities() int aPos = Search(aSubs[i], myEntities); if (aPos >= 0 && aPos < (int)myEntities.size()) { for (int j = 0; j < 4; j++) - if (myEntities[aPos].point[j] != 0) + if (myEntities[aPos].point[j] != SLVS_E_UNKNOWN) anUnusedEntities.erase(myEntities[aPos].point[j]); + if (myEntities[aPos].distance != SLVS_E_UNKNOWN) + anUnusedEntities.erase(myEntities[aPos].distance); } } }