plugins: Don't free static variable
authorJoão Valverde <joao.valverde@tecnico.ulisboa.pt>
Wed, 23 May 2018 15:58:05 +0000 (16:58 +0100)
committerJoão Valverde <j@v6e.pt>
Wed, 23 May 2018 16:06:27 +0000 (16:06 +0000)
Our convention is to pass a pointer to a static structure as argument
to *_register_plugin(). Don't try to free it.

Change-Id: I16d81b72faf298ebfb3dccf4c9d4772291fd8cf0
Reviewed-on: https://code.wireshark.org/review/27748
Reviewed-by: João Valverde <j@v6e.pt>
epan/epan.c

index 560d1f541391450978934512ad981d9c7704bc43..3dfcde7c42531fd2596f921cdcc8b212acb1f1a7 100644 (file)
@@ -298,7 +298,7 @@ epan_cleanup(void)
 {
 #ifdef HAVE_PLUGINS
        g_slist_foreach(epan_plugins, epan_plugin_cleanup, NULL);
-       g_slist_free_full(epan_plugins, g_free);
+       g_slist_free(epan_plugins);
        epan_plugins = NULL;
 #endif
        g_slist_free(epan_register_all_procotols);