diff options
Diffstat (limited to 'cpp/test/Ice/threads/Server.cpp')
-rw-r--r-- | cpp/test/Ice/threads/Server.cpp | 59 |
1 files changed, 0 insertions, 59 deletions
diff --git a/cpp/test/Ice/threads/Server.cpp b/cpp/test/Ice/threads/Server.cpp deleted file mode 100644 index 376d50fc83b..00000000000 --- a/cpp/test/Ice/threads/Server.cpp +++ /dev/null @@ -1,59 +0,0 @@ -// ********************************************************************** -// -// Copyright (c) 2003-2008 ZeroC, Inc. All rights reserved. -// -// This copy of Ice is licensed to you under the terms described in the -// ICE_LICENSE file included in this distribution. -// -// ********************************************************************** - -#include <Ice/Ice.h> -#include <TestI.h> - -using namespace std; - -int -run(int argc, char* argv[], const Ice::CommunicatorPtr& communicator) -{ - communicator->getProperties()->setProperty("TestAdapter.Endpoints", "default -p 12010 -t 10000:udp"); - Ice::ObjectAdapterPtr adapter = communicator->createObjectAdapter("TestAdapter"); - Ice::Identity id = communicator->stringToIdentity("server"); - adapter->add(new ServerI(communicator), id); - adapter->activate(); - - communicator->waitForShutdown(); - return EXIT_SUCCESS; -} - -int -main(int argc, char* argv[]) -{ - int status; - Ice::CommunicatorPtr communicator; - - try - { - communicator = Ice::initialize(argc, argv); - status = run(argc, argv, 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 status; -} |