aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-dhcpv6.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2015-11-08 20:15:22 -0500
committerMichael Mann <mmann78@netscape.net>2015-11-09 15:59:42 +0000
commit0aa9e9864721d5f425ffeba85bbb642ebd12e771 (patch)
tree98918da5fd1c719a3ca17b6df2369a663ed66550 /epan/dissectors/packet-dhcpv6.c
parent8f529628338f20948e80835076b7b18f6d48c6cf (diff)
Convert some UDP subdissectors to "new" style.
Change-Id: I3c1ee97f68af4539b97d50b75c03ff82147dbc5e Reviewed-on: https://code.wireshark.org/review/11649 Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-dhcpv6.c')
-rw-r--r--epan/dissectors/packet-dhcpv6.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/epan/dissectors/packet-dhcpv6.c b/epan/dissectors/packet-dhcpv6.c
index fa947fb671..5a5a688d18 100644
--- a/epan/dissectors/packet-dhcpv6.c
+++ b/epan/dissectors/packet-dhcpv6.c
@@ -2001,14 +2001,15 @@ dissect_dhcpv6(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
off += dhcpv6_option(tvb, pinfo, bp_tree, off, eoff, &at_end, proto_dhcpv6, hpi);
}
-static void
-dissect_dhcpv6_stream(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
+static int
+dissect_dhcpv6_stream(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
{
hopcount_info hpi;
initialize_hopount_info(&hpi);
col_set_str(pinfo->cinfo, COL_PROTOCOL, "DHCPv6");
col_clear(pinfo->cinfo, COL_INFO);
dissect_dhcpv6(tvb, pinfo, tree, 0, tvb_reported_length(tvb), hpi);
+ return tvb_captured_length(tvb);
}
static guint
@@ -2397,7 +2398,7 @@ proto_register_dhcpv6(void)
expert_register_field_array(expert_dhcpv6_bulk_leasequery, ei_bulk_leasequery, array_length(ei_bulk_leasequery));
/* Allow other dissectors to find this one by name. */
- register_dissector("dhcpv6", dissect_dhcpv6_stream, proto_dhcpv6);
+ new_register_dissector("dhcpv6", dissect_dhcpv6_stream, proto_dhcpv6);
dhcpv6_module = prefs_register_protocol(proto_dhcpv6, NULL);
prefs_register_bool_preference(dhcpv6_module, "cablelabs_interface_id",
@@ -2417,7 +2418,7 @@ proto_reg_handoff_dhcpv6(void)
{
dissector_handle_t dhcpv6_handle, dhcpv6_bulkquery_handle;
- dhcpv6_handle = create_dissector_handle(dissect_dhcpv6_stream, proto_dhcpv6);
+ dhcpv6_handle = new_create_dissector_handle(dissect_dhcpv6_stream, proto_dhcpv6);
dissector_add_uint("udp.port", UDP_PORT_DHCPV6_DOWNSTREAM, dhcpv6_handle);
dissector_add_uint("udp.port", UDP_PORT_DHCPV6_UPSTREAM, dhcpv6_handle);