aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2004-03-29 06:22:57 +0000
committerDaniel Stenberg <daniel@haxx.se>2004-03-29 06:22:57 +0000
commitd85c21994f849c8ef98152023435622f42b4dc95 (patch)
tree80e1e50e3efea12600e9fbc3f1ef7b04dfce34b3
parent6b33a5f954c11d77c82ead15e3e5560ca8568c42 (diff)
netinet/tcp.h may require netinet/in.h to be include before
-rw-r--r--configure.ac3
-rw-r--r--lib/connect.c5
2 files changed, 8 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index e188bc900..ad40ede97 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1038,6 +1038,9 @@ dnl default includes
#ifdef HAVE_SYS_SOCKET_H
#include <sys/socket.h>
#endif
+#ifdef HAVE_NETINET_IN_H
+#include <netinet/in.h>
+#endif
]
)
diff --git a/lib/connect.c b/lib/connect.c
index 77bcb56d1..78338de65 100644
--- a/lib/connect.c
+++ b/lib/connect.c
@@ -32,10 +32,15 @@
#ifdef HAVE_SYS_SOCKET_H
#include <sys/socket.h>
#endif
+#ifdef HAVE_NETINET_IN_H
+#include <netinet/in.h> /* <netinet/tcp.h> may need it */
+#endif
#ifdef HAVE_NETINET_TCP_H
#include <netinet/tcp.h> /* for TCP_NODELAY */
#endif
+#ifdef HAVE_SYS_IOCTL_H
#include <sys/ioctl.h>
+#endif
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif