aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--epan/conversation_table.c13
-rw-r--r--epan/conversation_table.h4
-rw-r--r--epan/epan.c2
3 files changed, 19 insertions, 0 deletions
diff --git a/epan/conversation_table.c b/epan/conversation_table.c
index db6e972aab..f64b36694d 100644
--- a/epan/conversation_table.c
+++ b/epan/conversation_table.c
@@ -828,6 +828,19 @@ add_hostlist_table_data(conv_hash_t *ch, const address *addr, guint32 port, gboo
}
}
+static void
+ct_table_free(gpointer p, gpointer user_data _U_)
+{
+ g_free(p);
+}
+
+void
+conversation_table_cleanup(void)
+{
+ g_slist_foreach(registered_ct_tables, ct_table_free, NULL);
+ g_slist_free(registered_ct_tables);
+}
+
/*
* Editor modelines
*
diff --git a/epan/conversation_table.h b/epan/conversation_table.h
index c0871924e2..ba94029bd9 100644
--- a/epan/conversation_table.h
+++ b/epan/conversation_table.h
@@ -340,6 +340,10 @@ add_conversation_table_data_with_conv_id(conv_hash_t *ch, const address *src, co
void add_hostlist_table_data(conv_hash_t *ch, const address *addr,
guint32 port, gboolean sender, int num_frames, int num_bytes, hostlist_dissector_info_t *host_info, port_type port_type_val);
+/** Cleanup internal structures
+ */
+void conversation_table_cleanup(void);
+
#ifdef __cplusplus
}
#endif /* __cplusplus */
diff --git a/epan/epan.c b/epan/epan.c
index 1ad91b2395..10dba580f7 100644
--- a/epan/epan.c
+++ b/epan/epan.c
@@ -61,6 +61,7 @@
#include "disabled_protos.h"
#include "decode_as.h"
#include "dissector_filters.h"
+#include "conversation_table.h"
#ifdef HAVE_LUA
#include <lua.h>
@@ -210,6 +211,7 @@ epan_cleanup(void)
proto_cleanup();
prefs_cleanup();
decode_clear_all();
+ conversation_table_cleanup();
conversation_filters_cleanup();
packet_cleanup();
expert_cleanup();