aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-rtp.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2017-01-28 19:53:36 -0500
committerMichael Mann <mmann78@netscape.net>2017-01-29 13:29:04 +0000
commitaf54b292e60fcdd8d03ec583e2b46c9c51f259a5 (patch)
tree67a4b61fd3e71ada67f2c27092a6849424759263 /epan/dissectors/packet-rtp.c
parented8ac81497c890bc82f161be727c0bb5285dcf12 (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-rtp.c')
-rw-r--r--epan/dissectors/packet-rtp.c19
1 files changed, 3 insertions, 16 deletions
diff --git a/epan/dissectors/packet-rtp.c b/epan/dissectors/packet-rtp.c
index 640ef2a24e..7b5c6eaf7d 100644
--- a/epan/dissectors/packet-rtp.c
+++ b/epan/dissectors/packet-rtp.c
@@ -907,20 +907,6 @@ rtp_dump_dyn_payload(rtp_dyn_payload_t *rtp_dyn_payload) {
}
#endif /* DEBUG_CONVERSATION */
-/* initialisation routine */
-static void
-rtp_fragment_init(void)
-{
- reassembly_table_init(&rtp_reassembly_table,
- &addresses_reassembly_table_functions);
-}
-
-static void
-rtp_fragment_cleanup(void)
-{
- reassembly_table_destroy(&rtp_reassembly_table);
-}
-
/* A single hash table to hold pointers to all the rtp_dyn_payload_t's we create/destroy.
This is necessary because we need to g_hash_table_destroy() them, either individually or
all at once at the end of the wmem file scope. Since rtp_dyn_payload_free() removes them
@@ -3822,8 +3808,9 @@ proto_register_rtp(void)
10,
&rtp_rfc2198_pt);
- register_init_routine(rtp_fragment_init);
- register_cleanup_routine(rtp_fragment_cleanup);
+ reassembly_table_register(&rtp_reassembly_table,
+ &addresses_reassembly_table_functions);
+
register_init_routine(rtp_dyn_payloads_init);
}