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.cpp16
1 files changed, 12 insertions, 4 deletions
diff --git a/cpp/src/Ice/Network.cpp b/cpp/src/Ice/Network.cpp
index f8f3b2e96b8..880c66e8ce3 100644
--- a/cpp/src/Ice/Network.cpp
+++ b/cpp/src/Ice/Network.cpp
@@ -22,10 +22,7 @@
// some definitions.
//
#if defined(__MINGW32__)
-# define _WIN32_WINNT 0x0501
-# ifndef IPV6_V6ONLY
-# define IPV6_V6ONLY 27
-# endif
+#define _WIN32_WINNT 0x0600
#endif
#include <IceUtil/DisableWarnings.h>
@@ -57,6 +54,17 @@
# include <sys/sockio.h>
#endif
+#if defined(__MINGW32__)
+# ifndef IPV6_V6ONLY
+# define IPV6_V6ONLY 27
+# endif
+
+extern "C"
+{
+ WINSOCK_API_LINKAGE int WSAAPI inet_pton(INT, PCTSTR, PVOID);
+}
+#endif
+
using namespace std;
using namespace Ice;
using namespace IceInternal;