diff options
author | Michael Mann <mmann78@netscape.net> | 2014-06-20 21:35:40 -0400 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2014-06-22 21:08:21 +0000 |
commit | 9356d5c689fa911b0b13d4b2a0cd6e9208d60f6d (patch) | |
tree | f3265efe4137c8a09995b448bf0c4bcdecf4e5a9 /asn1/camel/packet-camel-template.c | |
parent | 2c0214efff7b3421355e42ee7f3075c2f3181d3e (diff) |
convert to proto_tree_add_subtree[_format] for ASN.1 dissectors
Change-Id: I753ca95e2e1b38bad2c09955317e648c525e40ef
Reviewed-on: https://code.wireshark.org/review/2509
Tested-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'asn1/camel/packet-camel-template.c')
-rw-r--r-- | asn1/camel/packet-camel-template.c | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/asn1/camel/packet-camel-template.c b/asn1/camel/packet-camel-template.c index 0a64de3386..1bbee0e1a8 100644 --- a/asn1/camel/packet-camel-template.c +++ b/asn1/camel/packet-camel-template.c @@ -1072,7 +1072,7 @@ dissect_camel_camelPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, asn static int dissect_camel_v1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, void* data) { - proto_item *item, *stat_item; + proto_item *item; proto_tree *tree = NULL, *stat_tree = NULL; struct tcap_private_t * p_private_tcap = (struct tcap_private_t*)data; asn1_ctx_t asn1_ctx; @@ -1097,8 +1097,7 @@ dissect_camel_v1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, voi if (gcamel_HandleSRT && gp_camelsrt_info->tcap_context ) { if (gcamel_DisplaySRT && tree) { - stat_item = proto_tree_add_text(tree, tvb, 0, 0, "Stat"); - stat_tree = proto_item_add_subtree(stat_item, ett_camel_stat); + stat_tree = proto_tree_add_subtree(tree, tvb, 0, 0, ett_camel_stat, NULL, "Stat"); } camelsrt_call_matching(tvb, pinfo, stat_tree, gp_camelsrt_info); tap_queue_packet(camel_tap, pinfo, gp_camelsrt_info); @@ -1110,7 +1109,7 @@ dissect_camel_v1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, voi static int dissect_camel_v2(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, void* data) { - proto_item *item, *stat_item; + proto_item *item; proto_tree *tree = NULL, *stat_tree = NULL; struct tcap_private_t * p_private_tcap = (struct tcap_private_t*)data; asn1_ctx_t asn1_ctx; @@ -1135,8 +1134,7 @@ dissect_camel_v2(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, voi if (gcamel_HandleSRT && gp_camelsrt_info->tcap_context ) { if (gcamel_DisplaySRT && tree) { - stat_item = proto_tree_add_text(tree, tvb, 0, 0, "Stat"); - stat_tree = proto_item_add_subtree(stat_item, ett_camel_stat); + stat_tree = proto_tree_add_subtree(tree, tvb, 0, 0, ett_camel_stat, NULL, "Stat"); } camelsrt_call_matching(tvb, pinfo, stat_tree, gp_camelsrt_info); tap_queue_packet(camel_tap, pinfo, gp_camelsrt_info); @@ -1148,7 +1146,7 @@ dissect_camel_v2(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, voi static int dissect_camel(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, void* data) { - proto_item *item, *stat_item; + proto_item *item; proto_tree *tree, *stat_tree = NULL; struct tcap_private_t * p_private_tcap = (struct tcap_private_t*)data; asn1_ctx_t asn1_ctx; @@ -1172,8 +1170,7 @@ dissect_camel(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, void* if (gcamel_HandleSRT && gp_camelsrt_info->tcap_context ) { if (gcamel_DisplaySRT && tree) { - stat_item = proto_tree_add_text(tree, tvb, 0, 0, "Stat"); - stat_tree = proto_item_add_subtree(stat_item, ett_camel_stat); + stat_tree = proto_tree_add_subtree(tree, tvb, 0, 0, ett_camel_stat, NULL, "Stat"); } camelsrt_call_matching(tvb, pinfo, stat_tree, gp_camelsrt_info); tap_queue_packet(camel_tap, pinfo, gp_camelsrt_info); |