summaryrefslogtreecommitdiff
path: root/client
diff options
context:
space:
mode:
authorTomas Bzatek <tbzatek@redhat.com>2013-01-17 11:57:43 +0100
committerTomas Bzatek <tbzatek@redhat.com>2013-01-17 11:57:43 +0100
commitfd135fe90ce9b9a568468c4ddb21e6d13135e80d (patch)
tree77a3a34834640f00797fb8b5e072b7356706231e /client
parent85e2ef5741bc0e165e6e74a70917bd7f0390444f (diff)
downloadgvfs-fd135fe90ce9b9a568468c4ddb21e6d13135e80d.tar.gz
Use g_list_free_full() where applicable
Diffstat (limited to 'client')
-rw-r--r--client/gdaemonfileenumerator.c3
-rw-r--r--client/gdaemonvfs.c3
-rw-r--r--client/gdaemonvolumemonitor.c3
-rw-r--r--client/gvfsfusedaemon.c3
4 files changed, 4 insertions, 8 deletions
diff --git a/client/gdaemonfileenumerator.c b/client/gdaemonfileenumerator.c
index f8cdcc97..0c3c6974 100644
--- a/client/gdaemonfileenumerator.c
+++ b/client/gdaemonfileenumerator.c
@@ -97,8 +97,7 @@ static void trigger_async_done (GDaemonFileEnumerator *daemon, gboo
static void
free_info_list (GList *infos)
{
- g_list_foreach (infos, (GFunc)g_object_unref, NULL);
- g_list_free (infos);
+ g_list_free_full (infos, g_object_unref);
}
static void
diff --git a/client/gdaemonvfs.c b/client/gdaemonvfs.c
index 3ca31a29..b712b22b 100644
--- a/client/gdaemonvfs.c
+++ b/client/gdaemonvfs.c
@@ -349,8 +349,7 @@ g_daemon_vfs_init (GDaemonVfs *vfs)
}
/* The above should have ref:ed the modules anyway */
- g_list_foreach (modules, (GFunc)g_type_module_unuse, NULL);
- g_list_free (modules);
+ g_list_free_full (modules, (GDestroyNotify)g_type_module_unuse);
g_free (mappers);
}
diff --git a/client/gdaemonvolumemonitor.c b/client/gdaemonvolumemonitor.c
index af381a6e..b73453b2 100644
--- a/client/gdaemonvolumemonitor.c
+++ b/client/gdaemonvolumemonitor.c
@@ -239,8 +239,7 @@ g_daemon_volume_monitor_finalize (GObject *object)
g_object_unref (monitor->mount_tracker);
- g_list_foreach (monitor->mounts, (GFunc)g_object_unref, NULL);
- g_list_free (monitor->mounts);
+ g_list_free_full (monitor->mounts, g_object_unref);
if (G_OBJECT_CLASS (g_daemon_volume_monitor_parent_class)->finalize)
(*G_OBJECT_CLASS (g_daemon_volume_monitor_parent_class)->finalize) (object);
diff --git a/client/gvfsfusedaemon.c b/client/gvfsfusedaemon.c
index 6bb21e7e..6ce5133c 100644
--- a/client/gvfsfusedaemon.c
+++ b/client/gvfsfusedaemon.c
@@ -408,8 +408,7 @@ mount_list_unlock (void)
static void
mount_list_free (void)
{
- g_list_foreach (mount_list, (GFunc) mount_record_free, NULL);
- g_list_free (mount_list);
+ g_list_free_full (mount_list, (GDestroyNotify) mount_record_free);
mount_list = NULL;
}