diff options
author | Michael Mann <mmann78@netscape.net> | 2017-01-28 19:53:36 -0500 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2017-01-29 13:29:04 +0000 |
commit | af54b292e60fcdd8d03ec583e2b46c9c51f259a5 (patch) | |
tree | 67a4b61fd3e71ada67f2c27092a6849424759263 /epan/dissectors/packet-tipc.c | |
parent | ed8ac81497c890bc82f161be727c0bb5285dcf12 (diff) |
Register reassembly tables
Register all reassembly tables with a central unit, allowing the
central unit to have the callback that initializes and destroys
the reassembly tables, rather than have dissectors do it individually.
Change-Id: Ic92619c06fb5ba6f1c3012f613cae14982e101d4
Reviewed-on: https://code.wireshark.org/review/19834
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-tipc.c')
-rw-r--r-- | epan/dissectors/packet-tipc.c | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/epan/dissectors/packet-tipc.c b/epan/dissectors/packet-tipc.c index b77a0792e3..4fec69ded5 100644 --- a/epan/dissectors/packet-tipc.c +++ b/epan/dissectors/packet-tipc.c @@ -578,20 +578,6 @@ void proto_reg_handoff_tipc(void); static reassembly_table tipc_msg_reassembly_table; - -static void -tipc_defragment_init(void) -{ - reassembly_table_init(&tipc_msg_reassembly_table, - &addresses_reassembly_table_functions); -} - -static void -tipc_defragment_cleanup(void) -{ - reassembly_table_destroy(&tipc_msg_reassembly_table); -} - static gchar* tipc_addr_value_to_buf(guint tipc_address, gchar *buf, int buf_len) { @@ -3035,8 +3021,8 @@ proto_register_tipc(void) /* Register by name */ tipc_handle = register_dissector("tipc", dissect_tipc, proto_tipc); - register_init_routine(tipc_defragment_init); - register_cleanup_routine(tipc_defragment_cleanup); + reassembly_table_register(&tipc_msg_reassembly_table, + &addresses_reassembly_table_functions); /* Register configuration options */ tipc_module = prefs_register_protocol(proto_tipc, NULL); |