Skip to content

Commit e39cbc6

Browse files
committed
Fix ensure_fit_for_subtraction() function when input shape is a solid
1 parent 9619543 commit e39cbc6

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/ifcgeom/IfcGeomFunctions.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,9 @@ bool IfcGeom::is_compound(const TopoDS_Shape& shape) {
126126

127127
const TopoDS_Shape& IfcGeom::ensure_fit_for_subtraction(const TopoDS_Shape& shape, TopoDS_Shape& solid) {
128128
const bool is_comp = IfcGeom::is_compound(shape);
129-
if ( ! is_comp ) return shape;
129+
if (!is_comp) {
130+
return solid = shape;
131+
}
130132
IfcGeom::create_solid_from_compound(shape, solid);
131133

132134
// If the SEW_SHELLS option had been set this precision had been applied

0 commit comments

Comments
 (0)