diff options
Diffstat (limited to 'apps/Gateway/Gateway/Proxy_Handler_Connector.cpp')
-rw-r--r-- | apps/Gateway/Gateway/Proxy_Handler_Connector.cpp | 70 |
1 files changed, 0 insertions, 70 deletions
diff --git a/apps/Gateway/Gateway/Proxy_Handler_Connector.cpp b/apps/Gateway/Gateway/Proxy_Handler_Connector.cpp deleted file mode 100644 index bb745117d0f..00000000000 --- a/apps/Gateway/Gateway/Proxy_Handler_Connector.cpp +++ /dev/null @@ -1,70 +0,0 @@ -// $Id$ - -#include "Proxy_Handler_Connector.h" - -Proxy_Handler_Connector::Proxy_Handler_Connector (void) -{ -} - -// Initiate (or reinitiate) a connection to the Proxy_Handler. - -int -Proxy_Handler_Connector::initiate_connection (Proxy_Handler *proxy_handler, - ACE_Synch_Options &synch_options) -{ - char addr_buf[MAXHOSTNAMELEN]; - - // Mark ourselves as idle so that the various iterators - // will ignore us until we are reconnected. - proxy_handler->state (Proxy_Handler::IDLE); - - // We check the remote addr second so that it remains in the addr_buf. - if (proxy_handler->local_addr ().addr_to_string (addr_buf, sizeof addr_buf) == -1 - || proxy_handler->remote_addr ().addr_to_string (addr_buf, sizeof addr_buf) == -1) - ACE_ERROR_RETURN ((LM_ERROR, "(%t) %p\n", - "can't obtain peer's address"), -1); - - // Try to connect to the Peer. - - if (this->connect (proxy_handler, proxy_handler->remote_addr (), - synch_options, proxy_handler->local_addr ()) == -1) - { - if (errno != EWOULDBLOCK) - { - proxy_handler->state (Proxy_Handler::FAILED); - ACE_DEBUG ((LM_DEBUG, "(%t) %p on address %s\n", - "connect", addr_buf)); - - return -1; - } - else - { - proxy_handler->state (Proxy_Handler::CONNECTING); - ACE_DEBUG ((LM_DEBUG, - "(%t) in the process of connecting to %s\n", - addr_buf)); - } - } - else - { - proxy_handler->state (Proxy_Handler::ESTABLISHED); - ACE_DEBUG ((LM_DEBUG, "(%t) connected to %s on %d\n", - addr_buf, proxy_handler->get_handle ())); - } - return 0; -} - -#if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) -template class ACE_Connector<Proxy_Handler, ACE_SOCK_CONNECTOR>; -template class ACE_Svc_Tuple<Proxy_Handler>; -template class ACE_Map_Manager<ACE_HANDLE, ACE_Svc_Tuple<Proxy_Handler> *, ACE_SYNCH_RW_MUTEX>; -template class ACE_Map_Iterator<ACE_HANDLE, ACE_Svc_Tuple<Proxy_Handler> *, ACE_SYNCH_RW_MUTEX>; -template class ACE_Map_Entry<ACE_HANDLE, ACE_Svc_Tuple<Proxy_Handler> *>; -#elif defined (ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA) -#pragma instantiate ACE_Connector<Proxy_Handler, ACE_SOCK_CONNECTOR> -#pragma instantiate ACE_Svc_Tuple<Proxy_Handler> -#pragma instantiate ACE_Map_Manager<ACE_HANDLE, ACE_Svc_Tuple<Proxy_Handler> *, ACE_SYNCH_RW_MUTEX> -#pragma instantiate ACE_Map_Iterator<ACE_HANDLE, ACE_Svc_Tuple<Proxy_Handler> *, ACE_SYNCH_RW_MUTEX> -#pragma instantiate ACE_Map_Entry<ACE_HANDLE, ACE_Svc_Tuple<Proxy_Handler> *> -#endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ - |