summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/tests/Bug_2709_Regression/TestImpl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/orbsvcs/tests/Bug_2709_Regression/TestImpl.cpp')
-rw-r--r--TAO/orbsvcs/tests/Bug_2709_Regression/TestImpl.cpp28
1 files changed, 28 insertions, 0 deletions
diff --git a/TAO/orbsvcs/tests/Bug_2709_Regression/TestImpl.cpp b/TAO/orbsvcs/tests/Bug_2709_Regression/TestImpl.cpp
new file mode 100644
index 00000000000..e81edb9b66e
--- /dev/null
+++ b/TAO/orbsvcs/tests/Bug_2709_Regression/TestImpl.cpp
@@ -0,0 +1,28 @@
+// $Id$
+
+#include "ace/OS_NS_unistd.h"
+#include "TestImpl.h"
+
+TestImpl::TestImpl (CORBA::ORB_ptr orb)
+ : orb_ (CORBA::ORB::_duplicate (orb))
+{
+}
+
+// virtual
+void TestImpl::myMethod (ACE_ENV_SINGLE_ARG_DECL)
+ ACE_THROW_SPEC ((CORBA::SystemException))
+{
+ ACE_DEBUG ((LM_ERROR, "(%P): TestImpl::myMethod called!.\n") );
+}
+
+
+// virtual
+void TestImpl::shutdown (ACE_ENV_SINGLE_ARG_DECL)
+ ACE_THROW_SPEC ((CORBA::SystemException))
+{
+ // Give the client thread time to return from the collocated
+ // call to this method before shutting down the ORB. We sleep
+ // to avoid BAD_INV_ORDER exceptions on fast dual processor machines.
+ ACE_OS::sleep (1);
+ this->orb_->shutdown ();
+}