diff options
Diffstat (limited to 'TAO')
-rw-r--r-- | TAO/ChangeLogs/ChangeLog-02a | 10 | ||||
-rw-r--r-- | TAO/orbsvcs/orbsvcs/SSLIOP/SSLIOP_Connection_Handler.cpp | 8 | ||||
-rw-r--r-- | TAO/tao/IIOP_Connection_Handler.cpp | 8 | ||||
-rw-r--r-- | TAO/tao/Pluggable.i | 14 | ||||
-rw-r--r-- | TAO/tao/Strategies/SHMIOP_Connection_Handler.cpp | 7 | ||||
-rw-r--r-- | TAO/tao/Strategies/UIOP_Connection_Handler.cpp | 7 |
6 files changed, 43 insertions, 11 deletions
diff --git a/TAO/ChangeLogs/ChangeLog-02a b/TAO/ChangeLogs/ChangeLog-02a index 565782c94de..e1a6c638b60 100644 --- a/TAO/ChangeLogs/ChangeLog-02a +++ b/TAO/ChangeLogs/ChangeLog-02a @@ -1,3 +1,13 @@ +Fri Jan 12 16:36:11 2001 Balachandran Natarajan <bala@cs.wustl.edu> + + * orbsvcs/orbsvcs/SSLIOP/SSLIOP_Connection_Handler.cpp: + * tao/IIOP_Connection_Handler.cpp: + * tao/Pluggable.i: + * tao/Strategies/SHMIOP_Connection_Handler.cpp: + * tao/Strategies/UIOP_Connection_Handler.cpp: We open the sockets + in non-blocking mode and but change it to blocking only for the + thread-per-connection option. + Fri Jan 12 11:32:01 2001 Ossama Othman <ossama@uci.edu> * orbsvcs/orbsvcs/LoadBalancing/ReplicaLocator.cpp (preinvoke): diff --git a/TAO/orbsvcs/orbsvcs/SSLIOP/SSLIOP_Connection_Handler.cpp b/TAO/orbsvcs/orbsvcs/SSLIOP/SSLIOP_Connection_Handler.cpp index ccb1c716184..cd99a2deb33 100644 --- a/TAO/orbsvcs/orbsvcs/SSLIOP/SSLIOP_Connection_Handler.cpp +++ b/TAO/orbsvcs/orbsvcs/SSLIOP/SSLIOP_Connection_Handler.cpp @@ -97,6 +97,10 @@ TAO_SSLIOP_Connection_Handler::open (void*) sizeof (int)) == -1) return -1; #endif /* ! ACE_LACKS_TCP_NODELAY */ + + if (this->peer ().enable (ACE_NONBLOCK) == -1) + return -1; + // Called by the <Strategy_Acceptor> when the handler is // completely connected. ACE_INET_Addr addr; @@ -164,6 +168,10 @@ TAO_SSLIOP_Connection_Handler::svc (void) // turned into an active object. Presumably, activation spawns a // thread with this method as the "worker function". + // Clear the non-blocking mode here + ACE_Flag_Manip::clr_flags (this->get_handle (), + ACE_NONBLOCK); + // Call the implementation here return this->svc_i (); } diff --git a/TAO/tao/IIOP_Connection_Handler.cpp b/TAO/tao/IIOP_Connection_Handler.cpp index 3d00252975d..7f72c5cd967 100644 --- a/TAO/tao/IIOP_Connection_Handler.cpp +++ b/TAO/tao/IIOP_Connection_Handler.cpp @@ -83,6 +83,10 @@ TAO_IIOP_Connection_Handler::open (void*) sizeof (int)) == -1) return -1; #endif /* ! ACE_LACKS_TCP_NODELAY */ + + if (this->peer ().enable (ACE_NONBLOCK) == -1) + return -1; + // Called by the <Strategy_Acceptor> when the handler is // completely connected. ACE_INET_Addr addr; @@ -147,6 +151,10 @@ TAO_IIOP_Connection_Handler::svc (void) // turned into an active object. Presumably, activation spawns a // thread with this method as the "worker function". + // Clear the non-blocking mode here + ACE_Flag_Manip::clr_flags (this->get_handle (), + ACE_NONBLOCK); + // Call the implementation here return this->svc_i (); } diff --git a/TAO/tao/Pluggable.i b/TAO/tao/Pluggable.i index 6dd717561a7..ba23e5ece2f 100644 --- a/TAO/tao/Pluggable.i +++ b/TAO/tao/Pluggable.i @@ -8,17 +8,9 @@ TAO_Transport::read (char *buf, size_t len, const ACE_Time_Value * /*max_wait_time*/) { - int val = 0; - - // Set it to blocking mode - ACE::record_and_set_non_blocking_mode (this->handle (), - val); - ssize_t ret = ACE::recv (this->handle (), - (void *) buf, - len); - ACE::restore_non_blocking_mode (this->handle (), - val); - return ret; + return ACE::recv (this->handle (), + (void *) buf, + len); } // @@ One of the orb_core () methods should be done away. Will visit diff --git a/TAO/tao/Strategies/SHMIOP_Connection_Handler.cpp b/TAO/tao/Strategies/SHMIOP_Connection_Handler.cpp index 290297866cb..24882c4697f 100644 --- a/TAO/tao/Strategies/SHMIOP_Connection_Handler.cpp +++ b/TAO/tao/Strategies/SHMIOP_Connection_Handler.cpp @@ -87,6 +87,9 @@ TAO_SHMIOP_Connection_Handler::open (void*) return -1; #endif /* ! ACE_LACKS_TCP_NODELAY */ + if (this->peer ().enable (ACE_NONBLOCK) == -1) + return -1; + // Called by the <Strategy_Acceptor> when the handler is // completely connected. ACE_INET_Addr addr; @@ -151,6 +154,10 @@ TAO_SHMIOP_Connection_Handler::svc (void) // turned into an active object. Presumably, activation spawns a // thread with this method as the "worker function". + // Clear the non-blocking mode here + ACE_Flag_Manip::clr_flags (this->get_handle (), + ACE_NONBLOCK); + // Call the implementation here return this->svc_i (); } diff --git a/TAO/tao/Strategies/UIOP_Connection_Handler.cpp b/TAO/tao/Strategies/UIOP_Connection_Handler.cpp index aebdda7ac6c..e9cf3c7c273 100644 --- a/TAO/tao/Strategies/UIOP_Connection_Handler.cpp +++ b/TAO/tao/Strategies/UIOP_Connection_Handler.cpp @@ -80,6 +80,9 @@ TAO_UIOP_Connection_Handler::open (void*) this->uiop_properties_->recv_buffer_size) == -1) return -1; + if (this->peer ().enable (ACE_NONBLOCK) == -1) + return -1; + // Called by the <Strategy_Acceptor> when the handler is completely // connected. ACE_UNIX_Addr addr; @@ -135,6 +138,10 @@ TAO_UIOP_Connection_Handler::svc (void) // turned into an active object. Presumably, activation spawns a // thread with this method as the "worker function". + // Clear the non-blocking mode here + ACE_Flag_Manip::clr_flags (this->get_handle (), + ACE_NONBLOCK); + // Call the implementation here return this->svc_i (); } |