mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-01-11 23:16:14 +01:00
GUnixVolumeMonitor: Make use of new g_list_copy_deep()
This commit is contained in:
parent
2fd6eb7e1c
commit
aae1633d0f
@ -105,28 +105,20 @@ static GList *
|
||||
get_mounts (GVolumeMonitor *volume_monitor)
|
||||
{
|
||||
GUnixVolumeMonitor *monitor;
|
||||
GList *l;
|
||||
|
||||
monitor = G_UNIX_VOLUME_MONITOR (volume_monitor);
|
||||
|
||||
l = g_list_copy (monitor->mounts);
|
||||
g_list_foreach (l, (GFunc)g_object_ref, NULL);
|
||||
|
||||
return l;
|
||||
return g_list_copy_deep (monitor->mounts, (GCopyFunc) g_object_ref, NULL);
|
||||
}
|
||||
|
||||
static GList *
|
||||
get_volumes (GVolumeMonitor *volume_monitor)
|
||||
{
|
||||
GUnixVolumeMonitor *monitor;
|
||||
GList *l;
|
||||
|
||||
monitor = G_UNIX_VOLUME_MONITOR (volume_monitor);
|
||||
|
||||
l = g_list_copy (monitor->volumes);
|
||||
g_list_foreach (l, (GFunc)g_object_ref, NULL);
|
||||
|
||||
return l;
|
||||
return g_list_copy_deep (monitor->volumes, (GCopyFunc) g_object_ref, NULL);
|
||||
}
|
||||
|
||||
static GList *
|
||||
|
Loading…
Reference in New Issue
Block a user