diff options
Diffstat (limited to 'cpp/src')
-rw-r--r-- | cpp/src/Glacier2/RoutingTable.cpp | 2 | ||||
-rw-r--r-- | cpp/src/Glacier2/SessionRouterI.cpp | 6 | ||||
-rw-r--r-- | cpp/src/Ice/ConnectionI.cpp | 6 | ||||
-rw-r--r-- | cpp/src/IceBridge/IceBridge.cpp | 11 | ||||
-rw-r--r-- | cpp/src/IceGrid/SessionManager.cpp | 2 |
5 files changed, 14 insertions, 13 deletions
diff --git a/cpp/src/Glacier2/RoutingTable.cpp b/cpp/src/Glacier2/RoutingTable.cpp index e6b090de4cb..feb329e61b6 100644 --- a/cpp/src/Glacier2/RoutingTable.cpp +++ b/cpp/src/Glacier2/RoutingTable.cpp @@ -65,7 +65,7 @@ Glacier2::RoutingTable::add(const ObjectProxySeq& unfiltered, const Current& cur if(!_verifier->verify(*prx)) { - current.con->close(CloseForcefully); + current.con->close(ICE_SCOPED_ENUM(ConnectionClose, Forcefully)); throw ObjectNotExistException(__FILE__, __LINE__); } ObjectPrx proxy = (*prx)->ice_twoway()->ice_secure(false)->ice_facet(""); // We add proxies in default form. diff --git a/cpp/src/Glacier2/SessionRouterI.cpp b/cpp/src/Glacier2/SessionRouterI.cpp index 512d371611f..daed57a99d1 100644 --- a/cpp/src/Glacier2/SessionRouterI.cpp +++ b/cpp/src/Glacier2/SessionRouterI.cpp @@ -80,7 +80,7 @@ public: // Close the connection otherwise the peer has no way to know that // the session has gone. // - _connection->close(CloseForcefully); + _connection->close(ICE_SCOPED_ENUM(ConnectionClose, Forcefully)); _router->destroySession(_connection); } } @@ -922,7 +922,7 @@ SessionRouterI::refreshSession(const Ice::ConnectionPtr& con) // Close the connection otherwise the peer has no way to know that the // session has gone. // - con->close(CloseForcefully); + con->close(ICE_SCOPED_ENUM(ConnectionClose, Forcefully)); throw SessionNotExistException(); } } @@ -1152,7 +1152,7 @@ SessionRouterI::getRouterImpl(const ConnectionPtr& connection, const Ice::Identi out << "rejecting request, no session is associated with the connection.\n"; out << "identity: " << identityToString(id); } - connection->close(CloseForcefully); + connection->close(ICE_SCOPED_ENUM(ConnectionClose, Forcefully)); throw ObjectNotExistException(__FILE__, __LINE__); } return 0; diff --git a/cpp/src/Ice/ConnectionI.cpp b/cpp/src/Ice/ConnectionI.cpp index 223326203d1..1341cc44e5b 100644 --- a/cpp/src/Ice/ConnectionI.cpp +++ b/cpp/src/Ice/ConnectionI.cpp @@ -498,17 +498,17 @@ Ice::ConnectionI::close(ConnectionClose mode) { IceUtil::Monitor<IceUtil::Mutex>::Lock sync(*this); - if(mode == ICE_ENUM(ConnectionClose, CloseForcefully)) + if(mode == ICE_SCOPED_ENUM(ConnectionClose, Forcefully)) { setState(StateClosed, ConnectionManuallyClosedException(__FILE__, __LINE__, false)); } - else if(mode == ICE_ENUM(ConnectionClose, CloseGracefully)) + else if(mode == ICE_SCOPED_ENUM(ConnectionClose, Gracefully)) { setState(StateClosing, ConnectionManuallyClosedException(__FILE__, __LINE__, true)); } else { - assert(mode == ICE_ENUM(ConnectionClose, CloseGracefullyAndWait)); + assert(mode == ICE_SCOPED_ENUM(ConnectionClose, GracefullyWithWait)); // // Wait until all outstanding requests have been completed. diff --git a/cpp/src/IceBridge/IceBridge.cpp b/cpp/src/IceBridge/IceBridge.cpp index 31ec58aae6c..f3f520cf678 100644 --- a/cpp/src/IceBridge/IceBridge.cpp +++ b/cpp/src/IceBridge/IceBridge.cpp @@ -167,7 +167,7 @@ public: // The incoming connection is already closed. There's no point in leaving the outgoing // connection open. // - outgoing->close(CloseGracefully); + outgoing->close(ICE_SCOPED_ENUM(ConnectionClose, Gracefully)); } else { @@ -206,7 +206,7 @@ public: // if(_incoming) { - _incoming->close(CloseGracefully); + _incoming->close(ICE_SCOPED_ENUM(ConnectionClose, Gracefully)); } } } @@ -258,18 +258,19 @@ public: } catch(const Ice::CloseConnectionException&) { - toBeClosed->close(CloseGracefully); + toBeClosed->close(ICE_SCOPED_ENUM(ConnectionClose, Gracefully)); } catch(const Ice::ConnectionManuallyClosedException& ex) { // // Connection was manually closed by the bridge. // - toBeClosed->close(ex.graceful ? CloseGracefully : CloseForcefully); + toBeClosed->close(ex.graceful ? ICE_SCOPED_ENUM(ConnectionClose, Gracefully) : + ICE_SCOPED_ENUM(ConnectionClose, Forcefully)); } catch(...) { - toBeClosed->close(CloseForcefully); + toBeClosed->close(ICE_SCOPED_ENUM(ConnectionClose, Forcefully)); } } diff --git a/cpp/src/IceGrid/SessionManager.cpp b/cpp/src/IceGrid/SessionManager.cpp index c9b371000ff..1aa2701574e 100644 --- a/cpp/src/IceGrid/SessionManager.cpp +++ b/cpp/src/IceGrid/SessionManager.cpp @@ -58,7 +58,7 @@ SessionManager::findAllQueryObjects(bool cached) { try { - connection->close(Ice::ICE_ENUM(ConnectionClose, CloseGracefullyAndWait)); + connection->close(Ice::ICE_SCOPED_ENUM(ConnectionClose, GracefullyWithWait)); } catch(const Ice::LocalException&) { |