]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Avoid removing distance entity from list of SolveSpace entities (issue #848)
authorazv <azv@opencascade.com>
Mon, 17 Aug 2015 12:40:20 +0000 (15:40 +0300)
committerazv <azv@opencascade.com>
Mon, 17 Aug 2015 12:41:25 +0000 (15:41 +0300)
src/SketchSolver/SketchSolver_Storage.cpp

index 2f2700fd22abd19f575fb9a3ecc09d9828198ace..a716b6859b2968ccc608e3fcd68efb85b3627c7e 100644 (file)
@@ -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);
         }
       }
     }