mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-04-25 08:36:52 +02:00
Be a bit more picky when deciding if mounts are internal
Complained about in bug 623780.
This commit is contained in:
parent
349aab2bd4
commit
29850d03e8
@ -242,18 +242,19 @@ g_unix_is_mount_path_system_internal (const char *mount_path)
|
|||||||
"/proc",
|
"/proc",
|
||||||
"/sbin",
|
"/sbin",
|
||||||
"/net",
|
"/net",
|
||||||
|
"/sys",
|
||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
|
|
||||||
if (is_in (mount_path, ignore_mountpoints))
|
if (is_in (mount_path, ignore_mountpoints))
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
if (g_str_has_prefix (mount_path, "/dev") ||
|
if (g_str_has_prefix (mount_path, "/dev/") ||
|
||||||
g_str_has_prefix (mount_path, "/proc") ||
|
g_str_has_prefix (mount_path, "/proc/") ||
|
||||||
g_str_has_prefix (mount_path, "/sys"))
|
g_str_has_prefix (mount_path, "/sys/"))
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
if (strstr (mount_path, "/.gvfs") != NULL)
|
if (g_str_has_suffix (mount_path, "/.gvfs"))
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user