diff options
author | Peter Wu <peter@lekensteyn.nl> | 2015-06-28 13:06:31 +0200 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2015-07-03 23:34:28 +0000 |
commit | 80f7ee063d371f0de989d51d40c6b4fabfbfb430 (patch) | |
tree | 9d69b4eb9445f73f88535f36be2374f528012b2d /epan/dissectors/packet-ber.c | |
parent | 750babc53acae3399f31d2160d6d719c51c8f222 (diff) |
Call reassembly_table_destroy for some dissectors
This patch adds reassembly_table_destroy calls as cleanup function for
dissectors which have a simple init routine that just calls
reassembly_table_init (comments are ignored).
The changes were automatically generated using
https://git.lekensteyn.nl/peter/wireshark-notes/diff/one-off/cleanup-rewrite.py?id=4cc0aec05dc67a51926a045e1955b7a956757b5e
(with the if and assignment parsers disabled).
The only difference from the autogenerated output is that the XXX
comments from the init routines in smb-pipe and tds dissectors are kept.
Change-Id: I64aedf7189877247282b30b0e0f83757be6199e7
Reviewed-on: https://code.wireshark.org/review/9222
Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-ber.c')
-rw-r--r-- | epan/dissectors/packet-ber.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/epan/dissectors/packet-ber.c b/epan/dissectors/packet-ber.c index 4630da439c..eeff690f73 100644 --- a/epan/dissectors/packet-ber.c +++ b/epan/dissectors/packet-ber.c @@ -1435,6 +1435,10 @@ static void ber_defragment_init(void) { &addresses_reassembly_table_functions); } +static void ber_defragment_cleanup(void) { + reassembly_table_destroy(&octet_segment_reassembly_table); +} + static int reassemble_octet_string(asn1_ctx_t *actx, proto_tree *tree, gint hf_id, tvbuff_t *tvb, int offset, guint32 con_len, gboolean ind, tvbuff_t **out_tvb) { @@ -4517,6 +4521,7 @@ proto_register_ber(void) register_ber_syntax_dissector("ASN.1", proto_ber, dissect_ber_syntax); register_init_routine(ber_defragment_init); + register_cleanup_routine(ber_defragment_cleanup); register_decode_as(&ber_da); } |