summaryrefslogtreecommitdiff
path: root/cpp/src/Ice/Network.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/Ice/Network.cpp')
-rw-r--r--cpp/src/Ice/Network.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/cpp/src/Ice/Network.cpp b/cpp/src/Ice/Network.cpp
index 9754769479a..e60712ab51a 100644
--- a/cpp/src/Ice/Network.cpp
+++ b/cpp/src/Ice/Network.cpp
@@ -868,6 +868,12 @@ IceInternal::createServerSocket(bool udp, const Address& addr, ProtocolSupport p
int flag = protocol == EnableIPv6 ? 1 : 0;
if(setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, (char*)&flag, int(sizeof(int))) == SOCKET_ERROR)
{
+#ifdef _WIN32
+ if(getSocketErrno() == WSAENOPROTOOPT)
+ {
+ return fd; // Windows XP doesn't support IPV6_V6ONLY
+ }
+#endif
closeSocketNoThrow(fd);
SocketException ex(__FILE__, __LINE__);
ex.error = getSocketErrno();