#ifdef references to various Juniper DLT_ values, so that we can build
even on systems with older libpcaps that lack them. (tcpdump isn't
supposed to *require* the corresponding version of libpcap, although it
works best with that version or later.)
diff --git a/print-juniper.c b/print-juniper.c
index fdfdeb8..bb63494 100644
--- a/print-juniper.c
+++ b/print-juniper.c
@@ -15,7 +15,7 @@
#ifndef lint
static const char rcsid[] _U_ =
- "@(#) $Header: /tcpdump/master/tcpdump/print-juniper.c,v 1.24 2005-07-21 11:42:23 hannes Exp $ (LBL)";
+ "@(#) $Header: /tcpdump/master/tcpdump/print-juniper.c,v 1.25 2005-07-29 23:51:16 guy Exp $ (LBL)";
#endif
#ifdef HAVE_CONFIG_H
@@ -835,6 +835,7 @@
/* DLT_ specific parsing */
switch(l2info->pictype) {
+#ifdef DLT_JUNIPER_MLPPP
case DLT_JUNIPER_MLPPP:
switch (l2info->cookie_type) {
case LS_COOKIE_ID:
@@ -849,6 +850,8 @@
break;
}
break;
+#endif
+#ifdef DLT_JUNIPER_MLFR
case DLT_JUNIPER_MLFR:
switch (l2info->cookie_type) {
case LS_COOKIE_ID:
@@ -870,6 +873,8 @@
break;
}
break;
+#endif
+#ifdef DLT_JUNIPER_MFR
case DLT_JUNIPER_MFR:
switch (l2info->cookie_type) {
case LS_COOKIE_ID:
@@ -888,6 +893,8 @@
break;
}
break;
+#endif
+#ifdef DLT_JUNIPER_ATM2
case DLT_JUNIPER_ATM2:
TCHECK2(p[0],4);
/* ATM cell relay control word present ? */
@@ -897,8 +904,13 @@
printf("control-word 0x%08x ",EXTRACT_32BITS(p));
}
break;
+#endif
+#ifdef DLT_JUNIPER_ATM1
case DLT_JUNIPER_ATM1:
+ break;
+#endif
default:
+ printf("Unknown Juniper DLT_ type %u: ", l2info->pictype);
break;
}