mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-01 23:13:40 +02:00
fix leak that occurs when multiple mount entries match the requested path
2008-12-12 Ryan Lortie <desrt@desrt.ca> * gio/gunixmounts.c (g_unix_mount_at): fix leak that occurs when multiple mount entries match the requested path svn path=/trunk/; revision=7742
This commit is contained in:
@@ -1054,7 +1054,7 @@ g_unix_mount_at (const char *mount_path,
|
||||
{
|
||||
mount_entry = l->data;
|
||||
|
||||
if (strcmp (mount_path, mount_entry->mount_path) == 0)
|
||||
if (!found && strcmp (mount_path, mount_entry->mount_path) == 0)
|
||||
found = mount_entry;
|
||||
else
|
||||
g_unix_mount_free (mount_entry);
|
||||
|
Reference in New Issue
Block a user