X-Git-Url: https://sigrok.org/gitweb/?p=libsigrokdecode.git;a=blobdiff_plain;f=decoder.c;h=7374b779453e015025b59ae6dc4b5f16e5416e09;hp=c195e4bd00710240f75733a34d04a939da694822;hb=4f0d192d748e987af43ec5b811a643eb0a8601b2;hpb=7969d8035530d40753c4f880c90a4e90f9679ccc diff --git a/decoder.c b/decoder.c index c195e4b..7374b77 100644 --- a/decoder.c +++ b/decoder.c @@ -1077,7 +1077,8 @@ SRD_API int srd_decoder_load_all(void) */ SRD_API int srd_decoder_unload_all(void) { - g_slist_foreach(pd_list, (GFunc)srd_decoder_unload, NULL); + for (GSList *l = pd_list; l; l = l->next) + srd_decoder_unload(l->data); g_slist_free(pd_list); pd_list = NULL;