diff options
author | Dario Lombardo <lomato@gmail.com> | 2017-01-20 12:33:18 +0100 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2017-01-20 21:03:18 +0000 |
commit | d6b19f59b722e85365653867578fb7e5305f53aa (patch) | |
tree | df8e62a07e050353fde61a5b0910827e9a9bbf5f | |
parent | 76d9d3dc5a0d69070a99d6d1304726028e1d7c2a (diff) | |
download | wireshark-d6b19f59b722e85365653867578fb7e5305f53aa.tar.gz |
packet: add post_dissectors cleanup.
Change-Id: I9924425f1754c151552f41e23d20c7d4e6f1bf29
Reviewed-on: https://code.wireshark.org/review/19696
Reviewed-by: Michael Mann <mmann78@netscape.net>
-rw-r--r-- | epan/packet.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/epan/packet.c b/epan/packet.c index 8d30663b4a..00d90d40a5 100644 --- a/epan/packet.c +++ b/epan/packet.c @@ -127,6 +127,9 @@ static GHashTable *depend_dissector_lists = NULL; * the final cleanup. */ static GSList *postseq_cleanup_routines; +static GPtrArray* post_dissectors = NULL; +static guint num_of_postdissectors = 0; + static void destroy_depend_dissector_list(void *data) { @@ -245,6 +248,8 @@ packet_cleanup(void) g_hash_table_destroy(heuristic_short_names); g_slist_foreach(shutdown_routines, &call_routine, NULL); g_slist_free(shutdown_routines); + if (post_dissectors) + g_ptr_array_free(post_dissectors, TRUE); } /* @@ -3232,9 +3237,6 @@ dissector_dump_dissector_tables(void) g_list_free(list); } -static GPtrArray* post_dissectors = NULL; -static guint num_of_postdissectors = 0; - void register_postdissector(dissector_handle_t handle) { |