projects
/
platform
/
upstream
/
glib.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
010913c
)
GIO: Hide mounts having a path element starting with dot
author
Tomas Bzatek
<tbzatek@redhat.com>
Tue, 16 Nov 2010 13:20:07 +0000
(14:20 +0100)
committer
Tomas Bzatek
<tbzatek@redhat.com>
Tue, 16 Nov 2010 13:20:07 +0000
(14:20 +0100)
When a mount is mounted to a directory whose path contains an element
starting with dot, let's treat it as hidden, just like the usual Unix
approach.
gio/gunixmounts.c
patch
|
blob
|
history
diff --git
a/gio/gunixmounts.c
b/gio/gunixmounts.c
index
b58ab62
..
f110351
100644
(file)
--- a/
gio/gunixmounts.c
+++ b/
gio/gunixmounts.c
@@
-1944,6
+1944,10
@@
g_unix_mount_guess_should_display (GUnixMountEntry *mount_entry)
mount_path = mount_entry->mount_path;
if (mount_path != NULL)
{
+ /* Hide mounts within a dot path, suppose it was a purpose to hide this mount */
+ if (g_strstr_len (mount_path, -1, "/.") != NULL)
+ return FALSE;
+
if (g_str_has_prefix (mount_path, "/media/"))
{
char *path;