summaryrefslogtreecommitdiff
path: root/win32
diff options
context:
space:
mode:
authorJan Dubois <jand@activestate.com>2011-03-18 17:45:10 -0700
committerJan Dubois <jand@activestate.com>2011-03-19 10:17:46 -0700
commit912c63ed00375338703043928cac3c740d00cc9d (patch)
treebf417c05dc6d58b6c8ade6bc4f3137ac3a8cc692 /win32
parentb59e75b34cef3fedd214c9b6ee744146cf8b3308 (diff)
downloadperl-912c63ed00375338703043928cac3c740d00cc9d.tar.gz
Fixup errno definitions for Windows
Redefine all winsock based Exxxx error constants used in the core: For VS2010 we don't want to use the errno.h values, and for older compiler versions we don't have a definition anyways. Also remove the warnings about VS2010 from README.win32, as they should all be resolved now.
Diffstat (limited to 'win32')
-rw-r--r--win32/include/sys/socket.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/win32/include/sys/socket.h b/win32/include/sys/socket.h
index 53abf0cd21..3b92b13d54 100644
--- a/win32/include/sys/socket.h
+++ b/win32/include/sys/socket.h
@@ -82,6 +82,18 @@
extern "C" {
#endif
+#undef ENOTSOCK
+#define ENOTSOCK WSAENOTSOCK
+
+#undef ECONNABORTED
+#define ECONNABORTED WSAECONNABORTED
+
+#undef ECONNRESET
+#define ECONNRESET WSAECONNRESET
+
+#undef EAFNOSUPPORT
+#define EAFNOSUPPORT WSAEAFNOSUPPORT
+
#ifdef USE_SOCKETS_AS_HANDLES
#ifndef PERL_FD_SETSIZE