From: vsr Date: Fri, 31 Oct 2014 09:05:09 +0000 (+0300) Subject: Fix a bug with raising exception on computing bonding box for invalid shape X-Git-Tag: V7_5_0b1~3 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=6b8f1473f717b642611c4a73c2220a4348839723;p=modules%2Fgeom.git Fix a bug with raising exception on computing bonding box for invalid shape --- diff --git a/src/GEOMUtils/GEOMUtils.cxx b/src/GEOMUtils/GEOMUtils.cxx index 44e55da79..2a28e34cc 100644 --- a/src/GEOMUtils/GEOMUtils.cxx +++ b/src/GEOMUtils/GEOMUtils.cxx @@ -813,6 +813,7 @@ Standard_Boolean GEOMUtils::PreciseBoundingBox (const TopoDS_Shape &theShape, Bnd_Box &theBox) { if ( theBox.IsVoid() ) BRepBndLib::Add( theShape, theBox ); + if ( theBox.IsVoid() ) return Standard_False; Standard_Real aBound[6]; theBox.Get(aBound[0], aBound[2], aBound[4], aBound[1], aBound[3], aBound[5]);