summaryrefslogtreecommitdiff
path: root/cpp/test/Ice/udp/Server.cpp
diff options
context:
space:
mode:
authorBenoit Foucher <benoit@zeroc.com>2012-10-26 14:50:18 +0200
committerBenoit Foucher <benoit@zeroc.com>2012-10-26 14:50:18 +0200
commit2dd83ba68e037d7d16e06d667eb71d4f5159e90d (patch)
treebc1a6c3bd31f8b1201d759137f4ea696532837da /cpp/test/Ice/udp/Server.cpp
parentWin32 IceBox/admin test failure (diff)
downloadice-2dd83ba68e037d7d16e06d667eb71d4f5159e90d.tar.bz2
ice-2dd83ba68e037d7d16e06d667eb71d4f5159e90d.tar.xz
ice-2dd83ba68e037d7d16e06d667eb71d4f5159e90d.zip
Fixed UDP IPv6 test failures on OS X
Diffstat (limited to 'cpp/test/Ice/udp/Server.cpp')
-rw-r--r--cpp/test/Ice/udp/Server.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/cpp/test/Ice/udp/Server.cpp b/cpp/test/Ice/udp/Server.cpp
index e5ed3b505f7..17d12eacb2f 100644
--- a/cpp/test/Ice/udp/Server.cpp
+++ b/cpp/test/Ice/udp/Server.cpp
@@ -37,16 +37,20 @@ run(int argc, char* argv[], const Ice::CommunicatorPtr& communicator)
adapter2->activate();
}
- string host;
+ string endpoint;
if(properties->getProperty("Ice.IPv6") == "1")
{
- host = "\"ff01::1:1\"";
+#if defined(__APPLE__)
+ endpoint = "udp -h \"ff02::1:1\" -p 12020 --interface \"lo0\"";
+#else
+ endpoint = "udp -h \"ff01::1:1\" -p 12020";
+#endif
}
else
{
- host = "239.255.1.1";
+ endpoint = "udp -h 239.255.1.1 -p 12020";
}
- properties->setProperty("McastTestAdapter.Endpoints", "udp -h " + host + " -p 12020");
+ properties->setProperty("McastTestAdapter.Endpoints", endpoint);
Ice::ObjectAdapterPtr mcastAdapter = communicator->createObjectAdapter("McastTestAdapter");
mcastAdapter->add(new TestIntfI, communicator->stringToIdentity("test"));
mcastAdapter->activate();