]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Issue #2890: Wrong partition result with planes and SIGSEGV
authorazv <azv@opencascade.com>
Wed, 20 Mar 2019 09:44:45 +0000 (12:44 +0300)
committerazv <azv@opencascade.com>
Wed, 20 Mar 2019 09:45:45 +0000 (12:45 +0300)
Check number of points in the result when verifying a wire is a rectangle.

src/GeomAPI/GeomAPI_Wire.cpp

index c1124a353d5fc2b9f30e2ee6c4402a7882ebc665..addd4ccb6c166c390d2997d77dec8ca32c6a1288 100644 (file)
@@ -119,7 +119,7 @@ bool GeomAPI_Wire::isRectangle(std::list<GeomPointPtr>& thePoints) const
     else
       return false;
   }
-  return true;
+  return thePoints.size() == 4;
 }
 
 //==================================================================================================