From 2d30fb4615f83a6962790adb16a687191305472b Mon Sep 17 00:00:00 2001 From: Thomas Krijnen Date: Thu, 29 Dec 2011 14:45:32 +0000 Subject: [PATCH] Catch errors in the processing of lists of shapes --- src/ifcgeom/IfcRegisterConvertShapes.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/ifcgeom/IfcRegisterConvertShapes.h b/src/ifcgeom/IfcRegisterConvertShapes.h index 54a2dc0139..22f8651413 100644 --- a/src/ifcgeom/IfcRegisterConvertShapes.h +++ b/src/ifcgeom/IfcRegisterConvertShapes.h @@ -1,7 +1,11 @@ #include "IfcRegisterUndef.h" #define SHAPES(T) \ if ( l->is(T::Class()) ) { \ - return IfcGeom::convert((T*)l,r); \ + try { \ + return IfcGeom::convert((T*)l,r); \ + } catch (...) { } \ + Ifc::LogMessage("Error","Failed to convert:",l->entity); \ + return false; \ } #include "IfcRegisterDef.h"