summaryrefslogtreecommitdiff
path: root/decoder.c
diff options
context:
space:
mode:
Diffstat (limited to 'decoder.c')
-rw-r--r--decoder.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/decoder.c b/decoder.c
index eba5a28..1151f05 100644
--- a/decoder.c
+++ b/decoder.c
@@ -992,13 +992,7 @@ SRD_API int srd_decoder_load_all(void)
*/
SRD_API int srd_decoder_unload_all(void)
{
- GSList *l;
- struct srd_decoder *dec;
-
- for (l = pd_list; l; l = l->next) {
- dec = l->data;
- srd_decoder_unload(dec);
- }
+ g_slist_foreach(pd_list, (GFunc)srd_decoder_unload, NULL);
g_slist_free(pd_list);
pd_list = NULL;