0021843: [CEA 658] Segmentation fault when using GHS3D on a 2D group

correct fillAncestorsMap() not to miss COMPOUNDs inside a COMPOUND
This commit is contained in:
eap 2012-09-07 08:00:48 +00:00
parent f8658faa90
commit 98ad123d21

View File

@ -1984,6 +1984,13 @@ void SMESH_Mesh::fillAncestorsMap(const TopoDS_Shape& theShape)
(TopAbs_ShapeEnum) ancType,
_mapAncestors );
}
// visit COMPOUNDs inside a COMPOUND that are not reachable by TopExp_Explorer
if ( theShape.ShapeType() == TopAbs_COMPOUND )
{
for ( TopoDS_Iterator sIt(theShape); sIt.More(); sIt.Next() )
if ( sIt.Value().ShapeType() == TopAbs_COMPOUND )
fillAncestorsMap( sIt.Value() );
}
}
//=============================================================================