summaryrefslogtreecommitdiff
path: root/cpp/test/Ice/defaultServant/Client.cpp
diff options
context:
space:
mode:
authorJose <jose@zeroc.com>2015-12-14 15:03:52 +0100
committerJose <jose@zeroc.com>2015-12-14 15:03:52 +0100
commit6655e277f685ce92788c7a5d88e9d9fcb4073dac (patch)
tree052b244e4085a797b3f55a3e596460fa991f1216 /cpp/test/Ice/defaultServant/Client.cpp
parentAdded copy constructor to C++98 CommunicatorHolder (diff)
downloadice-6655e277f685ce92788c7a5d88e9d9fcb4073dac.tar.bz2
ice-6655e277f685ce92788c7a5d88e9d9fcb4073dac.tar.xz
ice-6655e277f685ce92788c7a5d88e9d9fcb4073dac.zip
C++11 mapping, binding/checksum/defaultServant tests
Diffstat (limited to 'cpp/test/Ice/defaultServant/Client.cpp')
-rw-r--r--cpp/test/Ice/defaultServant/Client.cpp25
1 files changed, 3 insertions, 22 deletions
diff --git a/cpp/test/Ice/defaultServant/Client.cpp b/cpp/test/Ice/defaultServant/Client.cpp
index d93d45b5a6d..c91e54113d8 100644
--- a/cpp/test/Ice/defaultServant/Client.cpp
+++ b/cpp/test/Ice/defaultServant/Client.cpp
@@ -21,7 +21,6 @@ run(int, char**, const Ice::CommunicatorPtr& communicator)
{
void allTests(const Ice::CommunicatorPtr&);
allTests(communicator);
-
return EXIT_SUCCESS;
}
@@ -31,32 +30,14 @@ main(int argc, char* argv[])
#ifdef ICE_STATIC_LIBS
Ice::registerIceSSL();
#endif
- int status;
- Ice::CommunicatorPtr communicator;
-
try
{
- communicator = Ice::initialize(argc, argv);
- status = run(argc, argv, communicator);
+ Ice::CommunicatorHolder ich = Ice::initialize(argc, argv);
+ return run(argc, argv, ich.communicator());
}
catch(const Ice::Exception& ex)
{
cerr << ex << endl;
- status = EXIT_FAILURE;
- }
-
- if(communicator)
- {
- try
- {
- communicator->destroy();
- }
- catch(const Ice::Exception& ex)
- {
- cerr << ex << endl;
- status = EXIT_FAILURE;
- }
+ return EXIT_FAILURE;
}
-
- return status;
}