diff options
author | Bill Meier <wmeier@newsguy.com> | 2013-09-09 14:26:41 +0000 |
---|---|---|
committer | Bill Meier <wmeier@newsguy.com> | 2013-09-09 14:26:41 +0000 |
commit | aa0e020324c94c4592939bc3441dd80e1962acd4 (patch) | |
tree | a2aad8497c304ec1655dac030e847501624e4a4c | |
parent | 955c89812db6c2f1e3ecfede387cc7bb8bdc01d3 (diff) |
Use a bunch of #includes only when needed. (2nd try; hat tip to Guy).
svn path=/trunk/; revision=51868
-rw-r--r-- | capture-pcap-util-unix.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/capture-pcap-util-unix.c b/capture-pcap-util-unix.c index 31def40f78..f0b6825ce0 100644 --- a/capture-pcap-util-unix.c +++ b/capture-pcap-util-unix.c @@ -28,6 +28,8 @@ #ifdef HAVE_LIBPCAP +#ifndef HAVE_PCAP_FINDALLDEVS + #include <stdlib.h> #include <string.h> #include <stdio.h> @@ -56,8 +58,15 @@ struct rtentry; # include <sys/sockio.h> #endif -#include "capture_ifinfo.h" #include "capture-pcap-util.h" + +#else + +#include <pcap.h> + +#endif /* HAVE_PCAP_FINDALLDEVS */ + +#include "capture_ifinfo.h" #include "capture-pcap-util-int.h" #ifndef HAVE_PCAP_FINDALLDEVS |