aboutsummaryrefslogtreecommitdiff
path: root/ares/adig.c
diff options
context:
space:
mode:
authorYang Tse <yangsita@gmail.com>2008-09-17 01:02:57 +0000
committerYang Tse <yangsita@gmail.com>2008-09-17 01:02:57 +0000
commit39de6c784cf6282b675250d521b79da5e010a412 (patch)
tree3c768e8568c696640a2019e32d2767c4db056d88 /ares/adig.c
parente5c4482088f327043e59a516490fbb36c5df926a (diff)
adjust inclusion of "nameser.h"
Diffstat (limited to 'ares/adig.c')
-rw-r--r--ares/adig.c35
1 files changed, 22 insertions, 13 deletions
diff --git a/ares/adig.c b/ares/adig.c
index 031ce8153..66b64a4ab 100644
--- a/ares/adig.c
+++ b/ares/adig.c
@@ -17,26 +17,35 @@
#include "setup.h"
-#if defined(WIN32) && !defined(WATT32)
-#include "nameser.h"
+#ifdef HAVE_SYS_SOCKET_H
+# include <sys/socket.h>
+#endif
+#ifdef HAVE_NETINET_IN_H
+# include <netinet/in.h>
+#endif
+#ifdef HAVE_ARPA_INET_H
+# include <arpa/inet.h>
+#endif
+#ifdef HAVE_NETDB_H
+# include <netdb.h>
+#endif
+#ifdef HAVE_ARPA_NAMESER_H
+# include <arpa/nameser.h>
#else
-#ifdef HAVE_SYS_TIME_H
-#include <sys/time.h>
+# include "nameser.h"
#endif
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
-#include <arpa/nameser.h>
#ifdef HAVE_ARPA_NAMESER_COMPAT_H
-#include <arpa/nameser_compat.h>
+# include <arpa/nameser_compat.h>
#endif
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
+
+#ifdef HAVE_SYS_TIME_H
+# include <sys/time.h>
#endif
-#include <netdb.h>
+#ifdef HAVE_UNISTD_H
+# include <unistd.h>
#endif
#ifdef HAVE_STRINGS_H
-#include <strings.h>
+# include <strings.h>
#endif
#include <stdio.h>