aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-osi-options.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2014-07-05 15:25:32 -0400
committerMichael Mann <mmann78@netscape.net>2014-07-05 20:36:36 +0000
commitfc63343a4ebebeb594a162c57bd1b17315a6e4d5 (patch)
treeb0f0c8b8e395a99f9fbbf95edad18b1370786e91 /epan/dissectors/packet-osi-options.c
parent3f7725174d2c4122b1d159958a56b8d8b928301b (diff)
convert to proto_tree_add_subtree[_format]
Change-Id: I8df48b25de784a48a25f0e48aac1e1545ed92c35 Reviewed-on: https://code.wireshark.org/review/2865 Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-osi-options.c')
-rw-r--r--epan/dissectors/packet-osi-options.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/epan/dissectors/packet-osi-options.c b/epan/dissectors/packet-osi-options.c
index 71f091debb..86a4792f7d 100644
--- a/epan/dissectors/packet-osi-options.c
+++ b/epan/dissectors/packet-osi-options.c
@@ -404,8 +404,7 @@ dissect_option_atn_security_label(const guchar sub_type, guchar length,
tvbuff_t *tvb, guint offset,
proto_tree *tree)
{
- proto_item *ti;
- proto_tree *atn_sl_tree = NULL;
+ proto_tree *atn_sl_tree;
guchar len = 0;
guint8 tag_name = 0;
guint security_info_end = 0;
@@ -423,10 +422,9 @@ dissect_option_atn_security_label(const guchar sub_type, guchar length,
if ( tvb_memeql(tvb, ++offset , atn_security_registration_val, OSI_OPT_SECURITY_ATN_SR_LEN) )
return;
- ti = proto_tree_add_text(tree, tvb, offset, length, "%s",
+ atn_sl_tree = proto_tree_add_subtree(tree, tvb, offset, length, ott_osi_qos, NULL,
val_to_str(sub_type, osi_opt_sec_atn_sr_vals, "Unknown (0x%x)"));
- atn_sl_tree = proto_item_add_subtree(ti, ott_osi_qos);
offset += OSI_OPT_SECURITY_ATN_SR_LEN;
/* Security Information length */
@@ -519,9 +517,8 @@ dissect_osi_options(guchar opt_len, tvbuff_t *tvb, int offset, proto_tree *tree)
return;
}
- ti = proto_tree_add_text(tree, tvb, offset, opt_len,
- "### Option Section ###");
- osi_option_tree = proto_item_add_subtree(ti, ott_osi_options);
+ osi_option_tree = proto_tree_add_subtree(tree, tvb, offset, opt_len,
+ ott_osi_options, &ti, "### Option Section ###");
while ( 0 < opt_len ) {
parm_type = tvb_get_guint8(tvb, offset++);