summaryrefslogtreecommitdiff
path: root/wsutil/inet_aton.h
diff options
context:
space:
mode:
authorJoão Valverde <joao.valverde@tecnico.ulisboa.pt>2016-02-10 07:16:08 +0000
committerJoão Valverde <j@v6e.pt>2016-02-13 23:51:53 +0000
commit2e85975feee4304ebc3e47c3b03653094b839b6c (patch)
tree49e3d4ba3ff3b04108621ea37d0b0e91e5598f76 /wsutil/inet_aton.h
parentd55f176a2472077eaad9315d525696d24b571e05 (diff)
downloadwireshark-2e85975feee4304ebc3e47c3b03653094b839b6c.tar.gz
Just #include wsutil/inet_aton.h
No need for platform-specific system header boilerplate. Change-Id: I5387a0005ddb0d7aab3c5b9f28d6282053c1b0fd Reviewed-on: https://code.wireshark.org/review/13865 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: João Valverde <j@v6e.pt>
Diffstat (limited to 'wsutil/inet_aton.h')
-rw-r--r--wsutil/inet_aton.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/wsutil/inet_aton.h b/wsutil/inet_aton.h
index bfccb2224f..3d89dc23c2 100644
--- a/wsutil/inet_aton.h
+++ b/wsutil/inet_aton.h
@@ -28,7 +28,25 @@
#include "ws_symbol_export.h"
+#ifdef HAVE_SYS_SOCKET_H
+#include <sys/socket.h> /* needed to define AF_ values on UNIX */
+#endif
+
+#ifdef HAVE_NETINET_IN_H
+# include <netinet/in.h>
+#endif
+
+#ifdef HAVE_ARPA_INET_H
+#include <arpa/inet.h>
+#endif
+
+#ifdef HAVE_WINSOCK2_H
+#include <winsock2.h>
+#endif
+
+#ifndef HAVE_INET_ATON
struct in_addr;
WS_DLL_PUBLIC int inet_aton(const char* cp_arg, struct in_addr *addr);
+#endif
#endif