From c2a8aa2bee81365b7d69470f59132b8e1dcf24c3 Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Wed, 22 Aug 2012 21:01:46 +0000 Subject: Put the state of flags in the hop_flags field into the summary line. Note in the introductory comment what "LISP" refers to, for the benefit of those of us who grew up thinking it stood for "LISt Processing". svn path=/trunk/; revision=44617 --- epan/dissectors/packet-lisp.c | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'epan/dissectors/packet-lisp.c') diff --git a/epan/dissectors/packet-lisp.c b/epan/dissectors/packet-lisp.c index b5dbc74f3e..2a1ec05b25 100644 --- a/epan/dissectors/packet-lisp.c +++ b/epan/dissectors/packet-lisp.c @@ -1,5 +1,5 @@ /* packet-lisp.c - * Routines for LISP Control Message dissection + * Routines for Locator/ID Separation Protocol (LISP) Control Message dissection * Copyright 2011, Lorand Jakab * * $Id$ @@ -319,11 +319,12 @@ dissect_lcaf_elp_hop(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, { guint16 addr_len = 0; guint16 hop_afi; + guint16 hop_flags; const gchar *hop_str; + proto_item *ti; hop_afi = tvb_get_ntohs(tvb, offset); offset += 2; - /* hop flags */ - offset += 2; + hop_flags = tvb_get_ntohs(tvb, offset); offset += 2; hop_str = get_addr_str(tvb, offset, hop_afi, &addr_len); if (hop_str == NULL) { @@ -333,10 +334,16 @@ dissect_lcaf_elp_hop(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, } if (idx) { - proto_tree_add_text(tree, tvb, offset - 4, addr_len + 4, "Reencap hop %d: %s", idx, hop_str); + ti = proto_tree_add_text(tree, tvb, offset - 4, addr_len + 4, "Reencap hop %d: %s", idx, hop_str); } else { - proto_tree_add_text(tree, tvb, offset - 4, addr_len + 4, "Reencap hop: %s", hop_str); + ti = proto_tree_add_text(tree, tvb, offset - 4, addr_len + 4, "Reencap hop: %s", hop_str); } + if (hop_flags & 0x04) + proto_item_append_text(ti, ", Lookup"); + if (hop_flags & 0x02) + proto_item_append_text(ti, ", RLOC-Probe"); + if (hop_flags & 0x01) + proto_item_append_text(ti, ", Strict"); return addr_len + 4; } -- cgit v1.2.3