aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-mpls-psc.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2015-11-15 16:51:45 -0500
committerMichael Mann <mmann78@netscape.net>2015-11-16 22:00:30 +0000
commit799d6fd057b0c20a7692a1181d811a8ff3a88d04 (patch)
tree31d6d1248aee7c3192ae6d854b43eeb2c0b996a0 /epan/dissectors/packet-mpls-psc.c
parent92bb13a4d22a48c43aa5fa6910c68829edebfdd0 (diff)
create_dissector_handle -> new_create_dissector_handle
Picking off "easy" dissectors that only have one or two exit points at most. Change-Id: I96aa9cf53533cbb07105aa400d42922baf3016b3 Reviewed-on: https://code.wireshark.org/review/11860 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-mpls-psc.c')
-rw-r--r--epan/dissectors/packet-mpls-psc.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/epan/dissectors/packet-mpls-psc.c b/epan/dissectors/packet-mpls-psc.c
index e3400fa8d4..a2d3d83ee4 100644
--- a/epan/dissectors/packet-mpls-psc.c
+++ b/epan/dissectors/packet-mpls-psc.c
@@ -108,8 +108,8 @@ const range_string mpls_psc_dpath_rvals[] = {
{ 0, 0, NULL }
};
-static void
-dissect_mpls_psc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_mpls_psc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
proto_item *ti;
proto_tree *psc_tree;
@@ -132,7 +132,7 @@ dissect_mpls_psc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
fpath, path);
if (!tree) {
- return;
+ return tvb_captured_length(tvb);
}
/* create display subtree for the protocol */
@@ -157,6 +157,7 @@ dissect_mpls_psc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
offset += 1;
/* tlv len */
proto_tree_add_item(psc_tree, hf_mpls_psc_tlvlen, tvb, offset, 1, ENC_BIG_ENDIAN);
+ return tvb_captured_length(tvb);
}
void
@@ -239,7 +240,7 @@ proto_reg_handoff_mpls_psc(void)
{
dissector_handle_t mpls_psc_handle;
- mpls_psc_handle = create_dissector_handle( dissect_mpls_psc, proto_mpls_psc );
+ mpls_psc_handle = new_create_dissector_handle( dissect_mpls_psc, proto_mpls_psc );
dissector_add_uint("pwach.channel_type", 0x0024, mpls_psc_handle); /* FF: PSC, RFC 6378 */
}