summaryrefslogtreecommitdiff
path: root/srd.c
diff options
context:
space:
mode:
Diffstat (limited to 'srd.c')
-rw-r--r--srd.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/srd.c b/srd.c
index 2947ca8..344919a 100644
--- a/srd.c
+++ b/srd.c
@@ -219,12 +219,9 @@ SRD_API int srd_init(const char *path)
*/
SRD_API int srd_exit(void)
{
- GSList *l;
-
srd_dbg("Exiting libsigrokdecode.");
- for (l = sessions; l; l = l->next)
- srd_session_destroy((struct srd_session *)l->data);
+ g_slist_foreach(sessions, (GFunc)srd_session_destroy, NULL);
srd_decoder_unload_all();
g_slist_free_full(searchpaths, g_free);