proto_tree_add_subtree[_format]
[metze/wireshark/wip.git] / epan / dissectors / packet-ipmi-transport.c
index 0e3d8769405a3675934f1b7687521cd1eb95538a..9249a6cca6747434a20a30a716eb60e8b68e3057 100644 (file)
@@ -915,7 +915,6 @@ lan_24(tvbuff_t *tvb, proto_tree *tree)
                &ett_ipmi_trn_lan24_byte4, &ett_ipmi_trn_lan24_byte5, &ett_ipmi_trn_lan24_byte6, &ett_ipmi_trn_lan24_byte7,
                &ett_ipmi_trn_lan24_byte8 };
        proto_tree *s_tree;
-       proto_item *ti;
        guint i;
        guint8 v, v1, v2;
 
@@ -923,11 +922,10 @@ lan_24(tvbuff_t *tvb, proto_tree *tree)
                v = tvb_get_guint8(tvb, i + 1);
                v1 = v & 0x0f;
                v2 = v >> 4;
-               ti = proto_tree_add_text(tree, tvb, i + 1, 1,
-                               "Cipher Suite #%d: %s (0x%02x), Cipher Suite #%d: %s (0x%02x)",
+               s_tree = proto_tree_add_subtree_format(tree, tvb, i + 1, 1,
+                               *ett[i], NULL, "Cipher Suite #%d: %s (0x%02x), Cipher Suite #%d: %s (0x%02x)",
                                i * 2 + 1, val_to_str_const(v1, lan24_priv_vals, "Reserved"), v1,
                                i * 2 + 2, val_to_str_const(v2, lan24_priv_vals, "Reserved"), v2);
-               s_tree = proto_item_add_subtree(ti, *ett[i]);
                proto_tree_add_uint_format(s_tree, hf_ipmi_trn_lan24_priv, tvb, i + 1, 1,
                                v2 << 4, "%sMaximum Privilege Level for Cipher Suite #%d: %s (0x%02x)",
                                ipmi_dcd8(v, 0xf0), i * 2 + 2, val_to_str_const(v2, lan24_priv_vals, "Reserved"), v2);