diff options
author | Benoit Foucher <benoit@zeroc.com> | 2014-07-25 17:47:36 +0200 |
---|---|---|
committer | Benoit Foucher <benoit@zeroc.com> | 2014-07-25 17:47:36 +0200 |
commit | e548dd63ec00b52e8d0f280b7a823516b8f61470 (patch) | |
tree | d3960c6fb761b135a4a6ad6cb991c1fa6f4d67f5 /cpp/src/IceGrid/ServerCache.cpp | |
parent | Improved IceGrid discovery, it now works with icegrid registry slaves and nodes (diff) | |
download | ice-e548dd63ec00b52e8d0f280b7a823516b8f61470.tar.bz2 ice-e548dd63ec00b52e8d0f280b7a823516b8f61470.tar.xz ice-e548dd63ec00b52e8d0f280b7a823516b8f61470.zip |
Fixed ICE-5595: Catch C++ exceptions by const reference
Diffstat (limited to 'cpp/src/IceGrid/ServerCache.cpp')
-rw-r--r-- | cpp/src/IceGrid/ServerCache.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/cpp/src/IceGrid/ServerCache.cpp b/cpp/src/IceGrid/ServerCache.cpp index 4db64ce189c..00a392a85cb 100644 --- a/cpp/src/IceGrid/ServerCache.cpp +++ b/cpp/src/IceGrid/ServerCache.cpp @@ -266,7 +266,7 @@ ServerEntry::waitForSyncNoThrow(int timeout) { waitImpl(timeout); } - catch(SynchronizationException&) + catch(const SynchronizationException&) { assert(timeout >= 0); } @@ -604,7 +604,7 @@ ServerEntry::syncImpl() { _cache.getNodeCache().get(destroy.node)->destroyServer(this, destroy, timeout); } - catch(NodeNotExistException&) + catch(const NodeNotExistException&) { exception(NodeUnreachableException(destroy.node, "node is not active")); } @@ -615,7 +615,7 @@ ServerEntry::syncImpl() { _cache.getNodeCache().get(load.node)->loadServer(this, load, session, timeout, noRestart); } - catch(NodeNotExistException&) + catch(const NodeNotExistException&) { exception(NodeUnreachableException(load.node, "node is not active")); } @@ -782,7 +782,7 @@ ServerEntry::loadCallback(const ServerPrx& proxy, const AdapterPrxDict& adpts, i { _cache.getNodeCache().get(destroy.node)->destroyServer(this, destroy, timeout); } - catch(NodeNotExistException&) + catch(const NodeNotExistException&) { exception(NodeUnreachableException(destroy.node, "node is not active")); } @@ -793,7 +793,7 @@ ServerEntry::loadCallback(const ServerPrx& proxy, const AdapterPrxDict& adpts, i { _cache.getNodeCache().get(load.node)->loadServer(this, load, session, timeout, noRestart); } - catch(NodeNotExistException&) + catch(const NodeNotExistException&) { exception(NodeUnreachableException(load.node, "node is not active")); } @@ -836,7 +836,7 @@ ServerEntry::destroyCallback() { _cache.getNodeCache().get(load.node)->loadServer(this, load, session, -1, noRestart); } - catch(NodeNotExistException&) + catch(const NodeNotExistException&) { exception(NodeUnreachableException(load.node, "node is not active")); } @@ -888,7 +888,7 @@ ServerEntry::exception(const Ice::Exception& ex) { _cache.getNodeCache().get(load.node)->loadServer(this, load, session, timeout, noRestart); } - catch(NodeNotExistException&) + catch(const NodeNotExistException&) { exception(NodeUnreachableException(load.node, "node is not active")); } @@ -942,7 +942,7 @@ ServerEntry::checkUpdate(const ServerInfo& info, bool noRestart) { node = _cache.getNodeCache().get(info.node); } - catch(NodeNotExistException&) + catch(const NodeNotExistException&) { throw NodeUnreachableException(info.node, "node is not active"); } |