]> SALOME platform Git repositories - modules/smesh.git/blobdiff - src/StdMeshers_I/StdMeshers_ViscousLayerBuilder_i.cxx
Salome HOME
Updated copyright comment
[modules/smesh.git] / src / StdMeshers_I / StdMeshers_ViscousLayerBuilder_i.cxx
index 3fc156116c4004dccf51e813825c3d6d58b66646..61328ba6209c667114c487f412531a8630385f81 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2007-2023  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2024  CEA/DEN, EDF R&D, OPEN CASCADE
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
@@ -188,8 +188,16 @@ CORBA::Boolean StdMeshers_ViscousLayerBuilder_i::AddLayers( SMESH::SMESH_Mesh_pt
   TopoDS_Shape theShape         = StdMeshers_ObjRefUlils::GeomObjectToShape( theShapeObject );
   SMESH_Mesh_i* shrinkMesh_i    = SMESH::DownCast< SMESH_Mesh_i* >( shrinkMesh );
   SMESH_Mesh_i* theFinalMesh_i  = SMESH::DownCast< SMESH_Mesh_i* >( finalMesh );
-  
-  bool success = GetImpl()->AddLayers( shrinkMesh_i->GetImpl(), theFinalMesh_i->GetImpl(), theShape );  
+  bool success = false;
+
+  try 
+  {
+    success = GetImpl()->AddLayers( shrinkMesh_i->GetImpl(), theFinalMesh_i->GetImpl(), theShape );  
+  }
+  catch ( std::exception& exc )
+  {
+    THROW_SALOME_CORBA_EXCEPTION( exc.what(), SALOME::INTERNAL_ERROR  );
+  }
   
   return success;
 }