diff options
author | coryan <coryan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2001-02-13 17:24:35 +0000 |
---|---|---|
committer | coryan <coryan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2001-02-13 17:24:35 +0000 |
commit | cff32df027b57c8031be6b82b9b5abdece590217 (patch) | |
tree | 079a1934623c4682eb382c1cdb3c96e95eee58ac /TAO/tests/Smart_Proxies | |
parent | 98873ef7f4e0aed5a26266f9e857d67247dce2b7 (diff) | |
download | ATCD-cff32df027b57c8031be6b82b9b5abdece590217.tar.gz |
ChangeLogTag:Tue Feb 13 09:17:30 2001 Carlos O'Ryan <coryan@uci.edu>
Diffstat (limited to 'TAO/tests/Smart_Proxies')
-rw-r--r-- | TAO/tests/Smart_Proxies/On_Demand/server.cpp | 30 | ||||
-rw-r--r-- | TAO/tests/Smart_Proxies/server.cpp | 30 |
2 files changed, 24 insertions, 36 deletions
diff --git a/TAO/tests/Smart_Proxies/On_Demand/server.cpp b/TAO/tests/Smart_Proxies/On_Demand/server.cpp index 79975e2e1d2..d72e3068539 100644 --- a/TAO/tests/Smart_Proxies/On_Demand/server.cpp +++ b/TAO/tests/Smart_Proxies/On_Demand/server.cpp @@ -27,7 +27,7 @@ class Test_i : public POA_Test { public: Test_i (CORBA::ORB_ptr orb); - + CORBA::Short method (CORBA::Short boo, CORBA::Environment &ACE_TRY_ENV) ACE_THROW_SPEC ((CORBA::SystemException, @@ -38,7 +38,7 @@ public: private: CORBA::ORB_var orb_; - + }; Test_i::Test_i (CORBA::ORB_ptr orb) @@ -110,14 +110,14 @@ main (int argc, char *argv[]) "", ACE_TRY_ENV); ACE_TRY_CHECK; - - Test_i servant (orb.in ()); + + Test_i servant (orb.in ()); // Obtain RootPOA. CORBA::Object_var object = - orb->resolve_initial_references ("RootPOA", + orb->resolve_initial_references ("RootPOA", ACE_TRY_ENV); - - PortableServer::POA_var root_poa = + + PortableServer::POA_var root_poa = PortableServer::POA::_narrow (object.in (), ACE_TRY_ENV); @@ -138,7 +138,7 @@ main (int argc, char *argv[]) // If the ior_output_file exists, output the ior to it if (ior_output_file != 0) { - FILE *output_file = + FILE *output_file = ACE_OS::fopen (ior_output_file, "w"); if (output_file == 0) @@ -156,13 +156,10 @@ main (int argc, char *argv[]) poa_manager->activate (ACE_TRY_ENV); ACE_TRY_CHECK; - if (orb->run () == -1) - ACE_ERROR_RETURN ((LM_ERROR, - "%p\n", - "orb->run"), - -1); - ACE_DEBUG ((LM_DEBUG, - "event loop finished\n")); + orb->run (ACE_TRY_ENV); + ACE_TRY_CHECK; + + ACE_DEBUG ((LM_DEBUG, "event loop finished\n")); root_poa->destroy (1, 1, @@ -178,6 +175,3 @@ main (int argc, char *argv[]) ACE_ENDTRY; return 0; } - - - diff --git a/TAO/tests/Smart_Proxies/server.cpp b/TAO/tests/Smart_Proxies/server.cpp index 22768dc39b3..bc3396c04d9 100644 --- a/TAO/tests/Smart_Proxies/server.cpp +++ b/TAO/tests/Smart_Proxies/server.cpp @@ -27,7 +27,7 @@ class Test_i : public POA_Test { public: Test_i (CORBA::ORB_ptr orb); - + CORBA::Short method (CORBA::Short boo, CORBA::Environment &ACE_TRY_ENV) ACE_THROW_SPEC ((CORBA::SystemException, @@ -38,7 +38,7 @@ public: private: CORBA::ORB_var orb_; - + }; Test_i::Test_i (CORBA::ORB_ptr orb) @@ -110,14 +110,14 @@ main (int argc, char *argv[]) "", ACE_TRY_ENV); ACE_TRY_CHECK; - - Test_i servant (orb.in ()); + + Test_i servant (orb.in ()); // Obtain RootPOA. CORBA::Object_var object = - orb->resolve_initial_references ("RootPOA", + orb->resolve_initial_references ("RootPOA", ACE_TRY_ENV); - - PortableServer::POA_var root_poa = + + PortableServer::POA_var root_poa = PortableServer::POA::_narrow (object.in (), ACE_TRY_ENV); @@ -138,7 +138,7 @@ main (int argc, char *argv[]) // If the ior_output_file exists, output the ior to it if (ior_output_file != 0) { - FILE *output_file = + FILE *output_file = ACE_OS::fopen (ior_output_file, "w"); if (output_file == 0) @@ -156,13 +156,10 @@ main (int argc, char *argv[]) poa_manager->activate (ACE_TRY_ENV); ACE_TRY_CHECK; - if (orb->run () == -1) - ACE_ERROR_RETURN ((LM_ERROR, - "%p\n", - "orb->run"), - -1); - ACE_DEBUG ((LM_DEBUG, - "event loop finished\n")); + orb->run (ACE_TRY_ENV); + ACE_TRY_CHECK; + + ACE_DEBUG ((LM_DEBUG, "event loop finished\n")); root_poa->destroy (1, 1, @@ -178,6 +175,3 @@ main (int argc, char *argv[]) ACE_ENDTRY; return 0; } - - - |