aboutsummaryrefslogtreecommitdiffstats
path: root/wiretap/libpcap.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>1999-08-22 19:08:40 +0000
committerGuy Harris <guy@alum.mit.edu>1999-08-22 19:08:40 +0000
commit73df88f11eeee326848d6848a67037b065c74b69 (patch)
tree12969a177b7d83f0ee5b436fe498ab30222f3c71 /wiretap/libpcap.c
parent7348611bcb004a928cf769034ef5eb3c27aff56e (diff)
Modify the comments to show how much of a mess the different DLT_ values
on different flavors of BSD are - even worse than I thought, now that I've seen the BSD/OS <net/bpf.h>. svn path=/trunk/; revision=552
Diffstat (limited to 'wiretap/libpcap.c')
-rw-r--r--wiretap/libpcap.c27
1 files changed, 18 insertions, 9 deletions
diff --git a/wiretap/libpcap.c b/wiretap/libpcap.c
index ff9bde6e4f..fc67af9876 100644
--- a/wiretap/libpcap.c
+++ b/wiretap/libpcap.c
@@ -1,6 +1,6 @@
/* libpcap.c
*
- * $Id: libpcap.c,v 1.13 1999/08/22 03:50:31 guy Exp $
+ * $Id: libpcap.c,v 1.14 1999/08/22 19:08:40 guy Exp $
*
* Wiretap Library
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
@@ -76,8 +76,9 @@ static int libpcap_dump(wtap_dumper *wdh, const struct wtap_pkthdr *phdr,
static int libpcap_dump_close(wtap_dumper *wdh, int *err);
/*
- * XXX - this is a bit of a mess. OpenBSD, and perhaps NetBSD, have
- * different DLT_ codes from FreeBSD (and from the LBL BPF code).
+ * XXX - this is a bit of a mess. OpenBSD, and perhaps NetBSD, and
+ * BSD/OS have different DLT_ codes from FreeBSD (and from the LBL
+ * BPF code), and, at least in some cases, from each other.
* For now, we simply treat those type values with different
* meanings on different platforms, except for DLT_RAW, as "unknown";
* this means you won't be able to capture from a network using those
@@ -108,12 +109,20 @@ static const int pcap_encap[] = {
WTAP_ENCAP_SLIP,
WTAP_ENCAP_PPP,
WTAP_ENCAP_FDDI,
- WTAP_ENCAP_ATM_RFC1483,
- WTAP_ENCAP_RAW_IP, /* or, on OpenBSD, DLT_LOOP */
- WTAP_ENCAP_UNKNOWN, /* BSD/OS SLIP *and* OpenBSD DLT_ENC */
- WTAP_ENCAP_UNKNOWN, /* BSD/OS PPP *and* OpenBSD DLT_RAW */
- WTAP_ENCAP_UNKNOWN, /* OpenBSD BSD/OS SLIP */
- WTAP_ENCAP_UNKNOWN, /* OpenBSD BSD/OS PPP */
+ WTAP_ENCAP_ATM_RFC1483, /* or, on BSD/OS, Frame Relay */
+ WTAP_ENCAP_RAW_IP, /* or, on OpenBSD, DLT_LOOP, and on BSD/OS,
+ Cisco HDLC */
+ WTAP_ENCAP_UNKNOWN, /* In LBL BPF and FreeBSD, BSD/OS SLIP;
+ on OpenBSD, DLT_ENC; on BSD/OS,
+ DLT_ATM_RFC1483 */
+ WTAP_ENCAP_UNKNOWN, /* In LBL BPF and FreeBSD, BSD/OS PPP;
+ on OpenBSD and BSD/OS, DLT_RAW */
+ WTAP_ENCAP_UNKNOWN, /* In OpenBSD and BSD/OS, BSD/OS SLIP,
+ but the BSD/OS header says "internal
+ to libpcap", whatever that means */
+ WTAP_ENCAP_UNKNOWN, /* In OpenBSD and BSD/OS, BSD/OS PPP,
+ but the BSD/OS header says "internal
+ to libpcap", whatever that means */
WTAP_ENCAP_UNKNOWN,
WTAP_ENCAP_UNKNOWN,
WTAP_ENCAP_LINUX_ATM_CLIP