summaryrefslogtreecommitdiff
path: root/TAO/tests/Bug_1693_Test/client.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/tests/Bug_1693_Test/client.cpp')
-rw-r--r--TAO/tests/Bug_1693_Test/client.cpp27
1 files changed, 9 insertions, 18 deletions
diff --git a/TAO/tests/Bug_1693_Test/client.cpp b/TAO/tests/Bug_1693_Test/client.cpp
index bb7a278ba2f..8baf5225fc2 100644
--- a/TAO/tests/Bug_1693_Test/client.cpp
+++ b/TAO/tests/Bug_1693_Test/client.cpp
@@ -11,23 +11,19 @@ ACE_RCSID (Codec,
int
main (int argc, char *argv[])
{
- ACE_DECLARE_NEW_CORBA_ENV;
- ACE_TRY
+ try
{
CORBA::ORB_var orb =
CORBA::ORB_init (argc,
argv,
- "my_orb"
- ACE_ENV_ARG_PARAMETER);
+ "my_orb");
// Obtain a reference to the CodecFactory.
CORBA::Object_var obj =
- orb->resolve_initial_references ("CodecFactory"
- ACE_ENV_ARG_PARAMETER);
+ orb->resolve_initial_references ("CodecFactory");
IOP::CodecFactory_var codec_factory =
- IOP::CodecFactory::_narrow (obj.in ()
- ACE_ENV_ARG_PARAMETER);
+ IOP::CodecFactory::_narrow (obj.in ());
// ----------------------------------------------------------
@@ -40,8 +36,7 @@ main (int argc, char *argv[])
// Obtain the CDR encapsulation Codec.
IOP::Codec_var codec =
- codec_factory->create_codec (encoding
- ACE_ENV_ARG_PARAMETER);
+ codec_factory->create_codec (encoding);
// ----------------------------------------------------------
{
@@ -55,13 +50,11 @@ main (int argc, char *argv[])
tmp <<= l;
encoded_data =
- codec->encode_value (tmp
- ACE_ENV_ARG_PARAMETER);
+ codec->encode_value (tmp);
decoded_data =
codec->decode_value (encoded_data.in (),
- Foo::_tc_type_ulong
- ACE_ENV_ARG_PARAMETER);
+ Foo::_tc_type_ulong);
Foo::type_ulong check = 0;
@@ -82,13 +75,11 @@ main (int argc, char *argv[])
ACE_DEBUG ((LM_DEBUG,
"(%P|%t) Test passed \n"));
}
- ACE_CATCHANY
+ catch (const CORBA::Exception& ex)
{
- ACE_PRINT_EXCEPTION (ACE_ANY_EXCEPTION,
- "Bug_1693_Test test:");
+ ex._tao_print_exception ("Bug_1693_Test test:");
return -1;
}
- ACE_ENDTRY;
return 0;
}