diff options
author | AndersBroman <anders.broman@ericsson.com> | 2017-02-16 16:13:41 +0100 |
---|---|---|
committer | Anders Broman <a.broman58@gmail.com> | 2017-02-16 21:03:44 +0000 |
commit | 16c3ecbd4c903815f4797f4f69daff98e9cb8807 (patch) | |
tree | bbe1541da5bf02d948674bdfe8f375fa8b9fa52d /epan/proto.c | |
parent | 14e19128dca1b318896ab7768d4527723dbefd17 (diff) |
g_slist_free_full requires glib 2.28
Change-Id: I4f9ce7f65da0349b962f6be317635c5acb2daf73
Reviewed-on: https://code.wireshark.org/review/20148
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
Diffstat (limited to 'epan/proto.c')
-rw-r--r-- | epan/proto.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/epan/proto.c b/epan/proto.c index 6484b6bab1..2e6cea999b 100644 --- a/epan/proto.c +++ b/epan/proto.c @@ -667,7 +667,12 @@ proto_cleanup(void) #ifdef HAVE_PLUGINS if (dissector_plugins) { +#if GLIB_CHECK_VERSION(2, 28, 0) g_slist_free_full(dissector_plugins, dissector_plugin_destroy); +#else + g_slist_foreach(dissector_plugins, (GFunc)dissector_plugin_destroy, NULL); + g_slist_free(dissector_plugins); +#endif dissector_plugins = NULL; } #endif |