]> granicus.if.org Git - python/commitdiff
Fix warning when compiling socketmodule.c with VS2010
authorKristján Valur Jónsson <kristjan@ccpgames.com>
Sat, 31 Mar 2012 13:35:00 +0000 (13:35 +0000)
committerKristján Valur Jónsson <kristjan@ccpgames.com>
Sat, 31 Mar 2012 13:35:00 +0000 (13:35 +0000)
VS2010 defineds the old errno constants in addition to the WSA* ones.

Modules/socketmodule.c

index df1c9f917fd2513d9f1fe06eeaa3c17829ce9c4e..d741d2cc4812db9adca01872d3f422cc5d0f8533 100644 (file)
@@ -390,6 +390,7 @@ dup_socket(SOCKET handle)
 #endif
 
 #ifdef MS_WIN32
+#undef EAFNOSUPPORT
 #define EAFNOSUPPORT WSAEAFNOSUPPORT
 #define snprintf _snprintf
 #endif