summaryrefslogtreecommitdiff
path: root/print-llc.c
diff options
context:
space:
mode:
authorhannes <hannes>2005-12-01 17:45:45 +0000
committerhannes <hannes>2005-12-01 17:45:45 +0000
commit46b52e5133d5fda0d7177280d79d16c5452f39ee (patch)
tree9c9bd4f742ec1827f2af59f3aa4facf22446da6a /print-llc.c
parent95f66c8c622d57b50443c4d40be8b00a7de0aa94 (diff)
downloadtcpdump-46b52e5133d5fda0d7177280d79d16c5452f39ee.tar.gz
bugfix: bogus SS codepoints, display ctrl field correct, added 'Poll' token for I/S frames
Diffstat (limited to 'print-llc.c')
-rw-r--r--print-llc.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/print-llc.c b/print-llc.c
index a797804b..d0ae8b20 100644
--- a/print-llc.c
+++ b/print-llc.c
@@ -24,7 +24,7 @@
#ifndef lint
static const char rcsid[] _U_ =
- "@(#) $Header: /tcpdump/master/tcpdump/print-llc.c,v 1.67 2005-11-13 12:12:42 guy Exp $";
+ "@(#) $Header: /tcpdump/master/tcpdump/print-llc.c,v 1.68 2005-12-01 17:45:45 hannes Exp $";
#endif
#ifdef HAVE_CONFIG_H
@@ -80,14 +80,16 @@ static const struct tok llc_flag_values[] = {
{ LLC_GSAP, "Response" },
{ LLC_U_POLL, "Poll" },
{ LLC_GSAP|LLC_U_POLL, "Final" },
+ { LLC_IS_POLL, "Poll" },
{ LLC_GSAP|LLC_IS_POLL, "Final" },
{ 0, NULL }
};
+
static const struct tok llc_supervisory_values[] = {
{ 0, "Receiver Ready" },
- { 1, "Reject" },
- { 2, "Receiver not Ready" },
+ { 1, "Receiver not Ready" },
+ { 2, "Reject" },
{ 0, NULL }
};
@@ -206,16 +208,17 @@ llc_print(const u_char *p, u_int length, u_int caplen,
ssap = ssap_field & ~LLC_GSAP;
if (eflag) {
- printf("LLC, dsap %s (0x%02x), ssap %s (0x%02x)",
+ printf("LLC, dsap %s (0x%02x), ssap %s (0x%02x) %s",
tok2str(llc_values, "Unknown", dsap),
dsap,
tok2str(llc_values, "Unknown", ssap),
- ssap);
+ ssap,
+ tok2str(llc_flag_values, "Unknown", ssap_field & LLC_GSAP));
if (is_u) {
- printf(", cmd 0x%02x: ", control);
+ printf(", ctrl 0x%02x: ", control);
} else {
- printf(", cmd 0x%04x: ", control);
+ printf(", ctrl 0x%04x: ", control);
}
}