From: adv Date: Thu, 16 Jan 2014 08:06:09 +0000 (+0000) Subject: Workaround replaced by correct piece of code. X-Git-Tag: BR_hydro_v_1_0~88 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=e69b1a5f5455d6028b2419e1cf557dbcbb604e0f;p=modules%2Fhydro.git Workaround replaced by correct piece of code. --- diff --git a/src/HYDROData/HYDROData_Region.cxx b/src/HYDROData/HYDROData_Region.cxx index 40699374..6548310b 100644 --- a/src/HYDROData/HYDROData_Region.cxx +++ b/src/HYDROData/HYDROData_Region.cxx @@ -188,17 +188,8 @@ void getUsedGroups( const TopoDS_Shape& theShape, { TopoDS_Shape aGroupEdge = anOriGroupDef.Shapes.Value( i ); - bool anIsFound = false; - for ( int anIndex = 1; anIndex <= aMapOfSubShapes.Extent(); anIndex++ ) - { - if ( aGroupEdge.IsPartner( aMapOfSubShapes.FindKey( anIndex ) ) ) - { - anIsFound = true; - break; - } - } - - if ( !anIsFound ) + int aShapeIndex = aMapOfSubShapes.FindIndex( aGroupEdge ); + if ( aShapeIndex <= 0 ) continue; anOriGroupDef.Shapes.Remove( i );