summaryrefslogtreecommitdiff
path: root/ACE/ace/Strategies_T.cpp
diff options
context:
space:
mode:
authorvzykov <vzykov@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2010-02-08 16:36:22 +0000
committervzykov <vzykov@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2010-02-08 16:36:22 +0000
commitf9c207c9ca81dac8b4658ae8e7a3bc38082fe51f (patch)
treecd649d0bb42b4606087dbc1f6dd4ae6217c9a85a /ACE/ace/Strategies_T.cpp
parent4791cdf67cb1a4cadb5ac069dd8821b6173b2b7d (diff)
downloadATCD-f9c207c9ca81dac8b4658ae8e7a3bc38082fe51f.tar.gz
Mon Feb 8 16:21:06 UTC 2010 Vladimir Zykov <vladimir.zykov@prismtech.com>
* ace/Strategies_T.cpp: Changed the code so that close() is called in case of failure instead of destroy(). * ace/Connector.cpp: Changed a bit the code added by me on 'Wed Sep 2 14:45:27 UTC 2009' as a fix for bug#3731. After some more thinking it turned out that the original code could result in a crash when reference counting is not enabled and thus svc_handler could be destroyed at the time when there was an attempt to do remove_reference(). * ace/Svc_Handler.cpp: Moved the code added by me on 'Thu Feb 4 11:15:57 UTC 2010' from destroy() to handle_close(). * tests/NonBlocking_Conn_Test.h: * tests/NonBlocking_Conn_Test.cpp: Extended the test for using Svc_Handler with and without reference counting.
Diffstat (limited to 'ACE/ace/Strategies_T.cpp')
-rw-r--r--ACE/ace/Strategies_T.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/ACE/ace/Strategies_T.cpp b/ACE/ace/Strategies_T.cpp
index 6aaef5eb2cc..4addb7d3774 100644
--- a/ACE/ace/Strategies_T.cpp
+++ b/ACE/ace/Strategies_T.cpp
@@ -439,7 +439,7 @@ ACE_Process_Strategy<SVC_HANDLER>::activate_svc_handler (SVC_HANDLER *svc_handle
case -1:
{
ACE_Errno_Guard error (errno);
- svc_handler->destroy ();
+ svc_handler->close ();
}
ACE_ERROR_RETURN ((LM_ERROR,
ACE_TEXT ("%p\n"),
@@ -462,7 +462,7 @@ ACE_Process_Strategy<SVC_HANDLER>::activate_svc_handler (SVC_HANDLER *svc_handle
default: // In parent process.
// We need to close down the <SVC_HANDLER> here because it's
// running in the child.
- svc_handler->destroy ();
+ svc_handler->close ();
return 0;
}
}