From: ribes Date: Mon, 30 Mar 2009 13:30:46 +0000 (+0000) Subject: _narrow cand send an exception ! X-Git-Tag: new_launcher_alpha_091119~31 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=83ee5cc81d8ad2e91de61222908da390ab4f93b8;p=modules%2Fkernel.git _narrow cand send an exception ! --- diff --git a/src/Container/SALOME_ContainerManager.cxx b/src/Container/SALOME_ContainerManager.cxx index fdf1465b1..1273018a2 100644 --- a/src/Container/SALOME_ContainerManager.cxx +++ b/src/Container/SALOME_ContainerManager.cxx @@ -145,32 +145,33 @@ void SALOME_ContainerManager::ShutdownContainers() for(list::iterator iter=lstCont.begin();iter!=lstCont.end();iter++){ SCRUTE((*iter)); } - for(list::iterator iter=lstCont.begin();iter!=lstCont.end();iter++){ - SCRUTE((*iter)); - CORBA::Object_var obj=_NS->Resolve((*iter).c_str()); - Engines::Container_var cont=Engines::Container::_narrow(obj); - if(!CORBA::is_nil(cont)) - { + for(list::iterator iter=lstCont.begin();iter!=lstCont.end();iter++) + { + try + { + SCRUTE((*iter)); + CORBA::Object_var obj=_NS->Resolve((*iter).c_str()); + Engines::Container_var cont=Engines::Container::_narrow(obj); + if(!CORBA::is_nil(cont)) + { MESSAGE("ShutdownContainers: " << (*iter)); - try - { - cont->Shutdown(); - } - catch(CORBA::SystemException& e) - { - INFOS("CORBA::SystemException ignored : " << e); - } - catch(CORBA::Exception&) - { - INFOS("CORBA::Exception ignored."); - } - catch(...) - { - INFOS("Unknown exception ignored."); - } - } - else - MESSAGE("ShutdownContainers: no container ref for " << (*iter)); + cont->Shutdown(); + } + else + MESSAGE("ShutdownContainers: no container ref for " << (*iter)); + } + catch(CORBA::SystemException& e) + { + INFOS("CORBA::SystemException ignored : " << e); + } + catch(CORBA::Exception&) + { + INFOS("CORBA::Exception ignored."); + } + catch(...) + { + INFOS("Unknown exception ignored."); + } } } }