aboutsummaryrefslogtreecommitdiffstats
path: root/pcap-bpf.c
diff options
context:
space:
mode:
Diffstat (limited to 'pcap-bpf.c')
-rw-r--r--pcap-bpf.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/pcap-bpf.c b/pcap-bpf.c
index 86d1bee..3cb91de 100644
--- a/pcap-bpf.c
+++ b/pcap-bpf.c
@@ -51,6 +51,7 @@ static const char rcsid[] _U_ =
#include <sys/ioccom.h>
#endif
#include <sys/utsname.h>
+#include <fcntl.h>
#ifdef HAVE_ZEROCOPY_BPF
#include <machine/atomic.h>
@@ -542,7 +543,8 @@ get_dlt_list(int fd, int v, struct bpf_dltlist *bdlp, char *ebuf)
if (v == DLT_EN10MB) {
is_ethernet = 1;
for (i = 0; i < bdlp->bfl_len; i++) {
- if (bdlp->bfl_list[i] != DLT_EN10MB) {
+ if (bdlp->bfl_list[i] != DLT_EN10MB &&
+ bdlp->bfl_list[i] != DLT_IPNET) {
is_ethernet = 0;
break;
}