aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-pktc.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2015-11-17 20:16:06 -0500
committerAnders Broman <a.broman58@gmail.com>2015-11-18 07:33:08 +0000
commit4adeb424f5cdb74ca1f98cd4b87bd72e4d811f03 (patch)
tree6c73d6e0795cc5181ad53242581e4c7f2282081f /epan/dissectors/packet-pktc.c
parent13297438d98e3388d650fc55c2a77d5b52367e1f (diff)
create_dissector_handle -> new_create_dissector_handle
Picking off "easy" dissectors that only have one or two exit points at most. Change-Id: I9c7d1c092bbae896ec0c2832617891346927f2e1 Reviewed-on: https://code.wireshark.org/review/11932 Reviewed-by: Michael Mann <mmann78@netscape.net> Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-pktc.c')
-rw-r--r--epan/dissectors/packet-pktc.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/epan/dissectors/packet-pktc.c b/epan/dissectors/packet-pktc.c
index 93a7d8905b..e6ed4064b4 100644
--- a/epan/dissectors/packet-pktc.c
+++ b/epan/dissectors/packet-pktc.c
@@ -547,8 +547,8 @@ static kerberos_callbacks cb[] = {
{ 0, NULL }
};
-static void
-dissect_pktc_mtafqdn(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_pktc_mtafqdn(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
int offset=0;
proto_tree *pktc_mtafqdn_tree;
@@ -572,11 +572,12 @@ dissect_pktc_mtafqdn(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
offset += dissect_kerberos_main(pktc_mtafqdn_tvb, pinfo, pktc_mtafqdn_tree, FALSE, cb);
proto_item_set_len(item, offset);
+ return tvb_captured_length(tvb);
}
-static void
-dissect_pktc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_pktc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
guint8 kmmid, doi, version;
int offset=0;
@@ -634,6 +635,7 @@ dissect_pktc(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
};
proto_item_set_len(item, offset);
+ return tvb_captured_length(tvb);
}
void
@@ -737,7 +739,7 @@ proto_reg_handoff_pktc(void)
{
dissector_handle_t pktc_handle;
- pktc_handle = create_dissector_handle(dissect_pktc, proto_pktc);
+ pktc_handle = new_create_dissector_handle(dissect_pktc, proto_pktc);
dissector_add_uint("udp.port", PKTC_PORT, pktc_handle);
}
@@ -797,7 +799,7 @@ proto_reg_handoff_pktc_mtafqdn(void)
{
dissector_handle_t pktc_mtafqdn_handle;
- pktc_mtafqdn_handle = create_dissector_handle(dissect_pktc_mtafqdn, proto_pktc_mtafqdn);
+ pktc_mtafqdn_handle = new_create_dissector_handle(dissect_pktc_mtafqdn, proto_pktc_mtafqdn);
dissector_add_uint("udp.port", PKTC_MTAFQDN_PORT, pktc_mtafqdn_handle);
}