mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-28 19:27:10 +00:00
Fix #861
This commit is contained in:
@@ -1925,6 +1925,7 @@ IfcGeom::BRepElement<P, PP>* IfcGeom::Kernel::create_brep_for_representation_and
|
|||||||
|
|
||||||
IfcSchema::IfcRepresentation* IfcGeom::Kernel::representation_mapped_to(const IfcSchema::IfcRepresentation* representation) {
|
IfcSchema::IfcRepresentation* IfcGeom::Kernel::representation_mapped_to(const IfcSchema::IfcRepresentation* representation) {
|
||||||
IfcSchema::IfcRepresentation* representation_mapped_to = 0;
|
IfcSchema::IfcRepresentation* representation_mapped_to = 0;
|
||||||
|
try {
|
||||||
IfcSchema::IfcRepresentationItem::list::ptr items = representation->Items();
|
IfcSchema::IfcRepresentationItem::list::ptr items = representation->Items();
|
||||||
if (items->size() == 1) {
|
if (items->size() == 1) {
|
||||||
IfcSchema::IfcRepresentationItem* item = *items->begin();
|
IfcSchema::IfcRepresentationItem* item = *items->begin();
|
||||||
@@ -1940,6 +1941,10 @@ IfcSchema::IfcRepresentation* IfcGeom::Kernel::representation_mapped_to(const If
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
} catch (const IfcParse::IfcException& e) {
|
||||||
|
Logger::Error(e);
|
||||||
|
// @todo reset representation_mapped_to to zero?
|
||||||
|
}
|
||||||
return representation_mapped_to;
|
return representation_mapped_to;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user