aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-usb-ccid.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2014-09-06 18:04:28 -0400
committerEvan Huus <eapache@gmail.com>2014-09-08 15:46:05 +0000
commitcf8f11f67876462510cc4254b845063c6cc047de (patch)
treec9fc47b3795bbb7bbb88c22a7c4014978342bd69 /epan/dissectors/packet-usb-ccid.c
parent433a444d148f86f2562f804d25a57d00dc277cc0 (diff)
Eliminate proto_tree_add_text from some of the dissectors.
Other minor cleanups while in the area. Change-Id: I623d941e53128f169e55dfc629547b4221fa72fc Reviewed-on: https://code.wireshark.org/review/4021 Reviewed-by: Michael Mann <mmann78@netscape.net> Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Evan Huus <eapache@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-usb-ccid.c')
-rw-r--r--epan/dissectors/packet-usb-ccid.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/epan/dissectors/packet-usb-ccid.c b/epan/dissectors/packet-usb-ccid.c
index a644abcd97..a17b95698b 100644
--- a/epan/dissectors/packet-usb-ccid.c
+++ b/epan/dissectors/packet-usb-ccid.c
@@ -70,6 +70,7 @@ static int hf_ccid_bClassEnvelope = -1;
static int hf_ccid_wLcdLayout = -1;
static int hf_ccid_bPINSupport = -1;
static int hf_ccid_bMaxCCIDBusySlots = -1;
+static int hf_ccid_Reserved = -1;
static dissector_handle_t usb_ccid_handle;
@@ -374,7 +375,7 @@ dissect_ccid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data)
proto_tree_add_item(ccid_tree, hf_ccid_bProtocolNum, tvb, 7, 1, ENC_LITTLE_ENDIAN);
/* Placeholder for abRFU */
- proto_tree_add_text(ccid_tree, tvb, 8, 2, "Reserved for Future Use");
+ proto_tree_add_item(ccid_tree, hf_ccid_Reserved, tvb, 8, 2, ENC_LITTLE_ENDIAN);
if (tvb_get_letohl(tvb, 1) != 0)
{
next_tvb = tvb_new_subset_remaining(tvb, 10);
@@ -389,7 +390,7 @@ dissect_ccid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data)
proto_tree_add_item(ccid_tree, hf_ccid_bPowerSelect, tvb, 7, 1, ENC_LITTLE_ENDIAN);
/* Placeholder for abRFU */
- proto_tree_add_text(ccid_tree, tvb, 8, 2, "Reserved for Future Use");
+ proto_tree_add_item(ccid_tree, hf_ccid_Reserved, tvb, 8, 2, ENC_LITTLE_ENDIAN);
break;
case PC_RDR_ICC_OFF:
@@ -398,7 +399,7 @@ dissect_ccid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data)
proto_tree_add_item(ccid_tree, hf_ccid_bSeq, tvb, 6, 1, ENC_LITTLE_ENDIAN);
/* Placeholder for abRFU */
- proto_tree_add_text(ccid_tree, tvb, 7, 3, "Reserved for Future Use");
+ proto_tree_add_item(ccid_tree, hf_ccid_Reserved, tvb, 7, 3, ENC_LITTLE_ENDIAN);
break;
case PC_RDR_GET_SLOT_STATUS:
@@ -407,7 +408,7 @@ dissect_ccid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data)
proto_tree_add_item(ccid_tree, hf_ccid_bSeq, tvb, 6, 1, ENC_LITTLE_ENDIAN);
/* Placeholder for abRFU */
- proto_tree_add_text(ccid_tree, tvb, 7, 3, "Reserved for Future Use");
+ proto_tree_add_item(ccid_tree, hf_ccid_Reserved, tvb, 7, 3, ENC_LITTLE_ENDIAN);
break;
case PC_RDR_GET_PARAMS:
@@ -416,7 +417,7 @@ dissect_ccid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data)
proto_tree_add_item(ccid_tree, hf_ccid_bSeq, tvb, 6, 1, ENC_LITTLE_ENDIAN);
/* Placeholder for abRFU */
- proto_tree_add_text(ccid_tree, tvb, 7, 3, "Reserved for Future Use");
+ proto_tree_add_item(ccid_tree, hf_ccid_Reserved, tvb, 7, 3, ENC_LITTLE_ENDIAN);
break;
case PC_RDR_XFR_BLOCK:
@@ -623,7 +624,10 @@ proto_register_ccid(void)
FT_UINT8, BASE_HEX, NULL, 0x0, NULL, HFILL }},
{&hf_ccid_bMaxCCIDBusySlots,
{ "maximum number of busy slots", "usbccid.hf_ccid_bMaxCCIDBusySlots",
- FT_UINT8, BASE_HEX, NULL, 0x0, NULL, HFILL }}
+ FT_UINT8, BASE_HEX, NULL, 0x0, NULL, HFILL }},
+ {&hf_ccid_Reserved,
+ { "Reserved for Future Use", "usbccid.hf_ccid_Reserved",
+ FT_UINT32, BASE_HEX, NULL, 0x0, NULL, HFILL }}
};
static gint *ett[] = {