summaryrefslogtreecommitdiff
path: root/TAO/tests/Collocation_Oneway_Tests
diff options
context:
space:
mode:
authorelliott_c <elliott_c@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2007-01-25 18:17:52 +0000
committerelliott_c <elliott_c@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2007-01-25 18:17:52 +0000
commit2ee7b7eed4c0cc10f4ec25b186b04202af01b565 (patch)
tree08a8a649c90559cf5b2228c1caad15515902613e /TAO/tests/Collocation_Oneway_Tests
parentc979767a00db4ea1299af482033a68829cc16675 (diff)
downloadATCD-2ee7b7eed4c0cc10f4ec25b186b04202af01b565.tar.gz
ChangeLogTag: Thu Jan 25 17:39:59 UTC 2007 Chad Elliott <elliott_c@ociweb.com>
Diffstat (limited to 'TAO/tests/Collocation_Oneway_Tests')
-rw-r--r--TAO/tests/Collocation_Oneway_Tests/Client_Task.cpp17
-rw-r--r--TAO/tests/Collocation_Oneway_Tests/Collocated_Test.cpp12
-rw-r--r--TAO/tests/Collocation_Oneway_Tests/Hello.cpp2
-rw-r--r--TAO/tests/Collocation_Oneway_Tests/Server_Task.cpp19
4 files changed, 19 insertions, 31 deletions
diff --git a/TAO/tests/Collocation_Oneway_Tests/Client_Task.cpp b/TAO/tests/Collocation_Oneway_Tests/Client_Task.cpp
index 16a2d78e815..a8ad8f92b03 100644
--- a/TAO/tests/Collocation_Oneway_Tests/Client_Task.cpp
+++ b/TAO/tests/Collocation_Oneway_Tests/Client_Task.cpp
@@ -24,14 +24,13 @@ Client_Task::Client_Task (const char *ior,
int
Client_Task::svc (void)
{
- ACE_TRY_NEW_ENV
+ try
{
CORBA::Object_var tmp =
- this->corb_->string_to_object (input_
- ACE_ENV_ARG_PARAMETER);
+ this->corb_->string_to_object (input_);
Test::Hello_var hello =
- Test::Hello::_narrow(tmp.in () ACE_ENV_ARG_PARAMETER);
+ Test::Hello::_narrow(tmp.in ());
if (CORBA::is_nil (hello.in ()))
{
@@ -67,10 +66,10 @@ Client_Task::svc (void)
CORBA::PolicyList polList;
polList.length(1);
polList[0] = this->corb_->create_policy(
- Messaging::SYNC_SCOPE_POLICY_TYPE, anyPolicy ACE_ENV_ARG_PARAMETER);
+ Messaging::SYNC_SCOPE_POLICY_TYPE, anyPolicy);
CORBA::Object_var tmpGenericVar =
- tmpVar->_set_policy_overrides(polList,CORBA::ADD_OVERRIDE ACE_ENV_ARG_PARAMETER);
+ tmpVar->_set_policy_overrides(polList,CORBA::ADD_OVERRIDE);
// do unchecked narrow because ORB's not activated. Otherwise get TRANSIENT exception
hello = Test::Hello::_narrow(tmpGenericVar.in());
@@ -95,13 +94,11 @@ Client_Task::svc (void)
hello->shutdown ();
}
- ACE_CATCHANY
+ catch (const CORBA::Exception& ex)
{
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught:");
+ ex._tao_print_exception ("Exception caught:");
return 1;
}
- ACE_ENDTRY;
return 0;
diff --git a/TAO/tests/Collocation_Oneway_Tests/Collocated_Test.cpp b/TAO/tests/Collocation_Oneway_Tests/Collocated_Test.cpp
index b5f46a9d86d..97635628029 100644
--- a/TAO/tests/Collocation_Oneway_Tests/Collocated_Test.cpp
+++ b/TAO/tests/Collocation_Oneway_Tests/Collocated_Test.cpp
@@ -74,15 +74,13 @@ main (int argc, char *argv[])
argv) == -1)
return -1;
- ACE_DECLARE_NEW_CORBA_ENV;
- ACE_TRY
+ try
{
ACE_Argv_Type_Converter satc (argc, argv);
CORBA::ORB_var sorb =
CORBA::ORB_init (satc.get_argc (),
satc.get_TCHAR_argv (),
- server_orb.c_str ()
- ACE_ENV_ARG_PARAMETER);
+ server_orb.c_str ());
ACE_Manual_Event me;
Server_Task server_task (output,
@@ -104,8 +102,7 @@ main (int argc, char *argv[])
CORBA::ORB_var corb =
CORBA::ORB_init (catc.get_argc (),
catc.get_TCHAR_argv (),
- client_orb.c_str ()
- ACE_ENV_ARG_PARAMETER);
+ client_orb.c_str ());
Client_Task client_task (input,
corb.in (),
@@ -121,10 +118,9 @@ main (int argc, char *argv[])
ACE_Thread_Manager::instance ()->wait ();
}
- ACE_CATCHANY
+ catch (const CORBA::Exception& ex)
{
// Ignore exceptions..
}
- ACE_ENDTRY;
return 0;
}
diff --git a/TAO/tests/Collocation_Oneway_Tests/Hello.cpp b/TAO/tests/Collocation_Oneway_Tests/Hello.cpp
index 7a212ffe621..8eb26a89ec3 100644
--- a/TAO/tests/Collocation_Oneway_Tests/Hello.cpp
+++ b/TAO/tests/Collocation_Oneway_Tests/Hello.cpp
@@ -71,5 +71,5 @@ void
Hello::shutdown (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
- this->orb_->shutdown (0 ACE_ENV_ARG_PARAMETER);
+ this->orb_->shutdown (0);
}
diff --git a/TAO/tests/Collocation_Oneway_Tests/Server_Task.cpp b/TAO/tests/Collocation_Oneway_Tests/Server_Task.cpp
index 8129e39ffc9..c6e578fa422 100644
--- a/TAO/tests/Collocation_Oneway_Tests/Server_Task.cpp
+++ b/TAO/tests/Collocation_Oneway_Tests/Server_Task.cpp
@@ -26,15 +26,13 @@ Server_Task::Server_Task (const char *output,
int
Server_Task::svc (void)
{
- ACE_TRY_NEW_ENV
+ try
{
CORBA::Object_var poa_object =
- this->sorb_->resolve_initial_references("RootPOA"
- ACE_ENV_ARG_PARAMETER);
+ this->sorb_->resolve_initial_references("RootPOA");
PortableServer::POA_var root_poa =
- PortableServer::POA::_narrow (poa_object.in ()
- ACE_ENV_ARG_PARAMETER);
+ PortableServer::POA::_narrow (poa_object.in ());
if (CORBA::is_nil (root_poa.in ()))
ACE_ERROR_RETURN ((LM_ERROR,
@@ -56,8 +54,7 @@ Server_Task::svc (void)
hello_impl->_this ();
CORBA::String_var ior =
- this->sorb_->object_to_string (hello.in ()
- ACE_ENV_ARG_PARAMETER);
+ this->sorb_->object_to_string (hello.in ());
// Output the IOR to the <this->output_>
FILE *output_file= ACE_OS::fopen (this->output_,
@@ -80,17 +77,15 @@ Server_Task::svc (void)
ACE_DEBUG ((LM_DEBUG, "(%P|%t) server - event loop finished\n"));
- root_poa->destroy (1, 1 ACE_ENV_ARG_PARAMETER);
+ root_poa->destroy (1, 1);
this->sorb_->destroy ();
}
- ACE_CATCHANY
+ catch (const CORBA::Exception& ex)
{
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Exception caught:");
+ ex._tao_print_exception ("Exception caught:");
return 1;
}
- ACE_ENDTRY;
return 0;
}