summaryrefslogtreecommitdiff
path: root/ACE/ace/INET_Addr.cpp
diff options
context:
space:
mode:
authorHuang-Ming Huang <huangming.huang@gmail.com>2017-04-10 10:04:05 -0500
committerHuang-Ming Huang <huangming.huang@gmail.com>2017-04-10 10:04:05 -0500
commit020cfd8d8ffa71ec6169287dc2e98cc0d4f7e815 (patch)
tree74ec57565a8fc34c0021c115983eb303a7fa0c39 /ACE/ace/INET_Addr.cpp
parent76dcc3fed2faf5c2148df8adb09ef3bc7b11b440 (diff)
downloadATCD-020cfd8d8ffa71ec6169287dc2e98cc0d4f7e815.tar.gz
Fix PR #394 compile error on some platform
Diffstat (limited to 'ACE/ace/INET_Addr.cpp')
-rw-r--r--ACE/ace/INET_Addr.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/ACE/ace/INET_Addr.cpp b/ACE/ace/INET_Addr.cpp
index e2d33e32ebb..a964a032630 100644
--- a/ACE/ace/INET_Addr.cpp
+++ b/ACE/ace/INET_Addr.cpp
@@ -415,7 +415,10 @@ ACE_INET_Addr::set (u_short port_number,
// Without AI_ALL, Windows machines exhibit inconsistent behaviors on
// difference machines we have tested.
- hints.ai_flags = AI_V4MAPPED | AI_ALL;
+ hints.ai_flags = AI_V4MAPPED;
+#if defined(ACE_HAS_IPV6) && defined(AI_ALL)
+ hints.ai_flags |= AI_ALL;
+#endif
// Note - specify the socktype here to avoid getting multiple entries
// returned with the same address for different socket types or