We should include netinet/in.h to use sockaddr_in (POSIX.1-2001)
authorTimothy Redaelli <timothy.redaelli@gmail.com>
Wed, 25 Apr 2012 12:07:24 +0000 (14:07 +0200)
committerLuke Dashjr <luke-jr+git@utopios.org>
Fri, 27 Apr 2012 14:42:37 +0000 (10:42 -0400)
src/net.cpp
src/protocol.cpp
src/protocol.h

index 5b3faea..e92c659 100644 (file)
@@ -12,6 +12,8 @@
 
 #ifdef WIN32
 #include <string.h>
+#else
+#include <netinet/in.h>
 #endif
 
 #ifdef USE_UPNP
index 9933452..16ad746 100644 (file)
@@ -8,6 +8,7 @@
 
 #ifndef WIN32
 # include <arpa/inet.h>
+# include <netinet/in.h>
 #endif
 
 // Prototypes from net.h, but that header (currently) stinks, can't #include it without breaking things
index 53d3eef..c8723fa 100644 (file)
 #ifndef __INCLUDED_PROTOCOL_H__
 #define __INCLUDED_PROTOCOL_H__
 
+#ifndef WIN32
+#include <netinet/in.h>
+#endif
+
 #include "serialize.h"
 #include <string>
 #include "uint256.h"