diff options
author | Guy Harris <guy@alum.mit.edu> | 2016-01-12 12:08:14 -0800 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2016-01-12 20:08:49 +0000 |
commit | 8b7020597af916c0e235fa70914bd4e5fcf57920 (patch) | |
tree | 1c627acdb8e9b6c52d5e25ab135d2116e8c8b9aa /extcap.c | |
parent | fea05007e461d6a6c25e8ccb5fe10ed4377e66ec (diff) | |
download | wireshark-8b7020597af916c0e235fa70914bd4e5fcf57920.tar.gz |
Don't use g_list_free_full().
It first appeared in GLib 2.28, and we support - and use, in the 32-bit
OS X buildbot - earlier versions.
Change-Id: I941a0206507e532c31cb13a918e3eb4d081e6ea3
Reviewed-on: https://code.wireshark.org/review/13240
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'extcap.c')
-rw-r--r-- | extcap.c | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -384,12 +384,16 @@ extcap_interface_list(char **err_str) { static void extcap_free_if_configuration(GList *list) { - GList *elem; + GList *elem, *sl; for (elem = g_list_first(list); elem; elem = elem->next) { - if (elem->data != NULL) - g_list_free_full(g_list_first((GList *)elem->data), g_free); + if (elem->data != NULL) { + /* g_list_free_full() only exists since 2.28. */ + sl = g_list_first((GList *)elem->data); + g_list_foreach(sl, (GFunc)g_free, NULL); + g_list_free(sl); + } } g_list_free(list); } |