summaryrefslogtreecommitdiff
path: root/iftop.c
diff options
context:
space:
mode:
authorpdw <>2011-10-02 21:41:47 +0000
committerpdw <>2011-10-02 21:41:47 +0000
commit120a1b2c5393fc63e2c9bf81d6adb55a6acd4ed2 (patch)
treea50dc5cf8eb811798d815c928e1fd09ccbd7c4fc /iftop.c
parent3e90c6b54712eb4e361edc31526c058712df7988 (diff)
downloadiftop-120a1b2c5393fc63e2c9bf81d6adb55a6acd4ed2.zip
FreeBSD patch from Frederic Perrin <frederic.perrin@resel.fr> plus fix for
compile error in gethostbyaddr resolver. Order of pcap.h vs bpf.h switched, to fix compilation on Mac OS X.
Diffstat (limited to 'iftop.c')
-rw-r--r--iftop.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/iftop.c b/iftop.c
index 97020ea..0c233cf 100644
--- a/iftop.c
+++ b/iftop.c
@@ -5,13 +5,6 @@
#include "integers.h"
-#if defined(HAVE_PCAP_H)
-# include <pcap.h>
-#elif defined(HAVE_PCAP_PCAP_H)
-# include <pcap/pcap.h>
-#else
-# error No pcap.h
-#endif
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
@@ -20,6 +13,13 @@
#include <sys/socket.h>
#include <net/if.h>
#include <net/bpf.h>
+#if defined(HAVE_PCAP_H)
+# include <pcap.h>
+#elif defined(HAVE_PCAP_PCAP_H)
+# include <pcap/pcap.h>
+#else
+# error No pcap.h
+#endif
#include <pthread.h>
#include <curses.h>