diff options
author | AndersBroman <anders.broman@ericsson.com> | 2017-07-13 12:41:12 +0200 |
---|---|---|
committer | Anders Broman <a.broman58@gmail.com> | 2017-07-13 14:08:12 +0000 |
commit | 9a29b96d2e9a11114c4fb1fa760198a2a12734c5 (patch) | |
tree | b94006f22dcdbe722d475073901f634ac5f37404 /epan/dissectors/packet-gtpv2.c | |
parent | 3c3c845f33566311e7ef0505a4633f9b5a4e8e49 (diff) |
[GTPv2] Make dissect_gtpv2_uli() external and add more info when calling
dissectors for private extensions.
Change-Id: I5762fdff2b25bca8d29520780c55367b636a2871
Reviewed-on: https://code.wireshark.org/review/22604
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-gtpv2.c')
-rw-r--r-- | epan/dissectors/packet-gtpv2.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/epan/dissectors/packet-gtpv2.c b/epan/dissectors/packet-gtpv2.c index f0bd0fa136..de8c67051a 100644 --- a/epan/dissectors/packet-gtpv2.c +++ b/epan/dissectors/packet-gtpv2.c @@ -2599,7 +2599,7 @@ decode_gtpv2_uli(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_item } -static void +void dissect_gtpv2_uli(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, proto_item *item, guint16 length, guint8 message_type _U_, guint8 instance _U_, session_args_t * args _U_) { proto_tree *flag_tree; @@ -5199,11 +5199,15 @@ dissect_gtpv2_fqdn(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, prot * 8.67 Private Extension */ static void -dissect_gtpv2_private_ext(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto_item *item _U_, guint16 length, guint8 message_type _U_, guint8 instance, session_args_t * args _U_) +dissect_gtpv2_private_ext(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto_item *item, guint16 length, guint8 message_type _U_, guint8 instance, session_args_t * args _U_) { int offset = 0; tvbuff_t *next_tvb; guint16 ext_id; + gtpv2_priv_ext_info_t gtpv2_inf; + + gtpv2_inf.instance = instance; + gtpv2_inf.item = item; /* oct 5 -7 Enterprise ID */ ext_id = tvb_get_ntohs(tvb, offset); @@ -5213,7 +5217,7 @@ dissect_gtpv2_private_ext(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tre proto_item_append_text(item, "%s (%u)", enterprises_lookup(ext_id, "Unknown"), ext_id); next_tvb = tvb_new_subset_length(tvb, offset, length-2); - if (dissector_try_uint_new(gtpv2_priv_ext_dissector_table, ext_id, next_tvb, pinfo, tree, FALSE, GUINT_TO_POINTER((guint32)instance))){ + if (dissector_try_uint_new(gtpv2_priv_ext_dissector_table, ext_id, next_tvb, pinfo, tree, FALSE, >pv2_inf)){ return; } |