summaryrefslogtreecommitdiff
path: root/cpp/test/IceGrid/replication/Server.cpp
diff options
context:
space:
mode:
authorJoe George <joe@zeroc.com>2021-02-03 11:16:06 -0500
committerJoe George <joe@zeroc.com>2021-02-03 11:42:30 -0500
commit48f9b28634908c43a23c30e219a9abfb038c1539 (patch)
tree81420c7142bb57902ad96de1d057b5259c29a287 /cpp/test/IceGrid/replication/Server.cpp
parentIceGrid and IceStorm fixes (diff)
downloadice-48f9b28634908c43a23c30e219a9abfb038c1539.tar.bz2
ice-48f9b28634908c43a23c30e219a9abfb038c1539.tar.xz
ice-48f9b28634908c43a23c30e219a9abfb038c1539.zip
Additional C++11 fixes
Diffstat (limited to 'cpp/test/IceGrid/replication/Server.cpp')
-rw-r--r--cpp/test/IceGrid/replication/Server.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/cpp/test/IceGrid/replication/Server.cpp b/cpp/test/IceGrid/replication/Server.cpp
index d21343f8f68..a0979fb2694 100644
--- a/cpp/test/IceGrid/replication/Server.cpp
+++ b/cpp/test/IceGrid/replication/Server.cpp
@@ -8,19 +8,19 @@
using namespace std;
-class Server : public Test::TestHelper
+class Server final : public Test::TestHelper
{
public:
- void run(int, char**);
+ void run(int, char**) override;
};
void
Server::run(int argc, char** argv)
{
- Ice::CommunicatorHolder communicator = initialize(argc, argv);
- Ice::ObjectAdapterPtr adapter = communicator->createObjectAdapter("TestAdapter");
- adapter->add(new TestI(), Ice::stringToIdentity(communicator->getProperties()->getProperty("Identity")));
+ Ice::CommunicatorHolder communicatorHolder = initialize(argc, argv);
+ auto adapter = communicatorHolder->createObjectAdapter("TestAdapter");
+ adapter->add(make_shared<TestI>(), Ice::stringToIdentity(communicatorHolder->getProperties()->getProperty("Identity")));
try
{
adapter->activate();
@@ -28,7 +28,7 @@ Server::run(int argc, char** argv)
catch(const Ice::ObjectAdapterDeactivatedException&)
{
}
- communicator->waitForShutdown();
+ communicatorHolder->waitForShutdown();
}
DEFINE_TEST(Server)