summaryrefslogtreecommitdiff
path: root/src/net/udp.h
diff options
context:
space:
mode:
authortomas <tomas@0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e>2008-07-14 11:45:35 +0000
committertomas <tomas@0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e>2008-07-14 11:45:35 +0000
commit8284a34173b34c0b6e5ffa9158dfceb4d286ecbc (patch)
tree76083e7886d9a67bef3c845678f7e1af60e9a790 /src/net/udp.h
parente792ee9cbe5191fcc81273b65bdb4ac9108435d5 (diff)
- port net/ na win32
- pridany inet_ntop () a inet_pton () pro win32 kvuli kompatibilite zdrojoveho kodu git-svn-id: http://opensvn.csie.org/tuxanci_ng@128 0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e
Diffstat (limited to 'src/net/udp.h')
-rw-r--r--src/net/udp.h13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/net/udp.h b/src/net/udp.h
index a9a38f6..ded5a6d 100644
--- a/src/net/udp.h
+++ b/src/net/udp.h
@@ -1,15 +1,26 @@
#ifndef MY_UDP
-#include <netinet/in.h>
+#ifndef __WIN32__
+# include <netinet/in.h>
+#else
+# include <windows.h>
+# include <wininet.h>
+#endif
#define MY_UDP
+#ifdef __WIN32__
#define SUPPORT_IPv6
+#endif
typedef struct struct_sock_udp_t
{
+#ifndef __WIN32__
int sock;
+#else
+ SOCKET sock;
+#endif
int proto;
#ifdef SUPPORT_IPv6