From 644445c7bce1cec14ad1ca666950a2ea14b61561 Mon Sep 17 00:00:00 2001 From: eap Date: Wed, 30 Jan 2013 07:35:49 +0000 Subject: [PATCH] do not netgen::multithread.task to error description if it is empty --- src/NETGENPlugin/NETGENPlugin_NETGEN_3D.cxx | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/NETGENPlugin/NETGENPlugin_NETGEN_3D.cxx b/src/NETGENPlugin/NETGENPlugin_NETGEN_3D.cxx index 131c40a..0e5a87f 100644 --- a/src/NETGENPlugin/NETGENPlugin_NETGEN_3D.cxx +++ b/src/NETGENPlugin/NETGENPlugin_NETGEN_3D.cxx @@ -403,10 +403,19 @@ bool NETGENPlugin_NETGEN_3D::compute(SMESH_Mesh& aMesh, str << ": " << ex.GetMessageString(); error(str); } + catch (netgen::NgException exc) + { + SMESH_Comment str("NgException"); + if ( strlen( netgen::multithread.task ) > 0 ) + str << " at " << netgen::multithread.task; + str << ": " << exc.What(); + error(str); + } catch (...) { SMESH_Comment str("Exception in netgen::OCCGenerateMesh()"); - str << " at " << netgen::multithread.task; + if ( strlen( netgen::multithread.task ) > 0 ) + str << " at " << netgen::multithread.task; error(str); } -- 2.39.2