diff options
author | Michael Mann <mmann78@netscape.net> | 2012-09-23 00:12:14 +0000 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2012-09-23 00:12:14 +0000 |
commit | b89a06a3e15546d177ba136bb46bfe1de97fa4fc (patch) | |
tree | 713968875728ff8e136aa9aad2a94b52872e6ac4 /epan/dissectors/packet-q2931.c | |
parent | 37b6ca2ce8ba54810f54f86c5c17170315ccd0eb (diff) |
replaced decode_boolean_bitfield calls with itemized filters
svn path=/trunk/; revision=45059
Diffstat (limited to 'epan/dissectors/packet-q2931.c')
-rw-r--r-- | epan/dissectors/packet-q2931.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/epan/dissectors/packet-q2931.c b/epan/dissectors/packet-q2931.c index 680a60869c..d26f358fa2 100644 --- a/epan/dissectors/packet-q2931.c +++ b/epan/dissectors/packet-q2931.c @@ -53,6 +53,7 @@ static int hf_q2931_message_type_ext = -1; static int hf_q2931_message_flag = -1; static int hf_q2931_message_action_indicator = -1; static int hf_q2931_message_len = -1; +static int hf_q2931_ie_handling_instructions = -1; static gint ett_q2931 = -1; static gint ett_q2931_ext = -1; @@ -248,6 +249,9 @@ static const value_string q2931_codeset_vals[] = { { 0x00, NULL }, }; +static const true_false_string tfs_q2931_handling_instructions = { "Follow explicit error handling instructions", + "Regular error handling procedures apply" }; + static void dissect_q2931_shift_ie(tvbuff_t *tvb, int offset, int len, proto_tree *tree, guint8 info_element) @@ -1990,11 +1994,7 @@ dissect_q2931_ie(tvbuff_t *tvb, int offset, int len, proto_tree *tree, decode_enumerated_bitfield(info_element_ext, Q2931_IE_COMPAT_CODING_STD, 8, coding_std_vals, "Coding standard: %s")); - proto_tree_add_text(ie_ext_tree, tvb, offset + 1, 1, "%s", - decode_boolean_bitfield(info_element_ext, - Q2931_IE_COMPAT_FOLLOW_INST, 8, - "Follow explicit error handling instructions", - "Regular error handling procedures apply")); + proto_tree_add_item(ie_ext_tree, hf_q2931_ie_handling_instructions, tvb, offset+1, 1, ENC_BIG_ENDIAN); if (info_element_ext & Q2931_IE_COMPAT_FOLLOW_INST) { proto_tree_add_text(ie_ext_tree, tvb, offset + 1, 1, "%s", decode_enumerated_bitfield(info_element_ext, @@ -2173,6 +2173,10 @@ proto_register_q2931(void) { "Message length", "q2931.message_len", FT_UINT16, BASE_DEC, NULL, 0x0, NULL, HFILL }}, + { &hf_q2931_ie_handling_instructions, + { "Handling Instructions", "q2931.ie_handling_instructions", FT_BOOLEAN, 8, TFS(&tfs_q2931_handling_instructions), Q2931_IE_COMPAT_FOLLOW_INST, + NULL, HFILL }}, + }; static gint *ett[] = { &ett_q2931, |