diff options
author | Jose <jose@zeroc.com> | 2009-01-07 17:26:37 +0100 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2009-01-07 17:26:37 +0100 |
commit | 36b3ac9c0e99b2e48c4ff8931895276b839b1a3c (patch) | |
tree | 85dc08fc4485ff9ed2dafec4ba5d341801d8dedb /cpp/src/Ice/PluginManagerI.cpp | |
parent | New test case for bug 3564 - IceGrid::Locator missing from .NET IceGrid.dll (diff) | |
download | ice-36b3ac9c0e99b2e48c4ff8931895276b839b1a3c.tar.bz2 ice-36b3ac9c0e99b2e48c4ff8931895276b839b1a3c.tar.xz ice-36b3ac9c0e99b2e48c4ff8931895276b839b1a3c.zip |
Other fix for 3601 - plugins can be destroyed twice
Diffstat (limited to 'cpp/src/Ice/PluginManagerI.cpp')
-rw-r--r-- | cpp/src/Ice/PluginManagerI.cpp | 30 |
1 files changed, 28 insertions, 2 deletions
diff --git a/cpp/src/Ice/PluginManagerI.cpp b/cpp/src/Ice/PluginManagerI.cpp index adc25621fb8..0b114402ac8 100644 --- a/cpp/src/Ice/PluginManagerI.cpp +++ b/cpp/src/Ice/PluginManagerI.cpp @@ -123,8 +123,34 @@ Ice::PluginManagerI::destroy() map<string, PluginPtr>::iterator r; for(r = _plugins.begin(); r != _plugins.end(); ++r) { - r->second->destroy(); - r->second = 0; + try + { + r->second->destroy(); + r->second = 0; + } + catch(const std::exception& ex) + { + Warning out(getProcessLogger()); + out << "unexpected exception raised by plug-in '" << r->first << "' destruction.\n"; + out << "exception: " << ex.what(); + } + catch(const std::string& str) + { + Warning out(getProcessLogger()); + out << "unexpected exception raised by plug-in '" << r->first << "' destruction.\n"; + out << "exception: " << str; + } + catch(const char* msg) + { + Warning out(getProcessLogger()); + out << "unexpected exception raised by plug-in '" << r->first << "' destruction.\n"; + out << "exception: " << msg; + } + catch(...) + { + Warning out(getProcessLogger()); + out << "unexpected exception raised by plug-in '" << r->first << "' destruction."; + } } } |