diff options
Diffstat (limited to 'ace/Connector.cpp')
-rw-r--r-- | ace/Connector.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/ace/Connector.cpp b/ace/Connector.cpp index a0e12e99768..db6c640a9bf 100644 --- a/ace/Connector.cpp +++ b/ace/Connector.cpp @@ -438,7 +438,7 @@ ACE_Connector<SH, PR_CO_2>::connect_i (SH *&sh, reuse_addr, flags, perms); - + // Delegate to connection strategy. if (result == -1) { @@ -615,7 +615,7 @@ ACE_Connector<SH, PR_CO_2>::close (void) } template <class SH, PR_CO_1> int -ACE_Connector<SH, PR_CO_2>::handle_close (ACE_HANDLE, ACE_Reactor_Mask) +ACE_Connector<SH, PR_CO_2>::handle_close (ACE_HANDLE, ACE_Reactor_Mask mask) { ACE_TRACE ("ACE_Connector<SH, PR_CO_2>::handle_close"); @@ -626,6 +626,10 @@ ACE_Connector<SH, PR_CO_2>::handle_close (ACE_HANDLE, ACE_Reactor_Mask) // Timer_Queue). this->closing_ = 1; + // Remove all timer objects associated with <this> object from + // the <Reactor>'s Timer_Queue. + this->reactor ()->cancel_timer (this); + MAP_ITERATOR mi (this->handler_map_); // Iterate through the map and shut down all the pending handlers. @@ -634,6 +638,9 @@ ACE_Connector<SH, PR_CO_2>::handle_close (ACE_HANDLE, ACE_Reactor_Mask) mi.next (me) != 0; mi.advance ()) { + this->reactor ()->remove_handler (me->ext_id_, + mask | ACE_Event_Handler::DONT_CALL); + AST *ast = 0; this->cleanup_AST (me->ext_id_, ast); |