Filesystem info is earlier than we get actually know the information
You can easily see this issue by using this debug code:
diff --git a/src/nautilus-directory-async.c b/src/nautilus-directory-async.c
index b261babcf..4bb5ccf89 100644
--- a/src/nautilus-directory-async.c
+++ b/src/nautilus-directory-async.c
@@ -3993,6 +3993,7 @@ got_filesystem_info (FilesystemInfoState *state,
const char *filesystem_type;
/* careful here, info may be NULL */
+ g_print("GOT FILE SYSTEM INFO %s\n",nautilus_file_get_uri(state->file));
directory = nautilus_directory_ref (state->directory);
diff --git a/src/nautilus-file.c b/src/nautilus-file.c
index 0eebcd1e2..aa864fd44 100644
--- a/src/nautilus-file.c
+++ b/src/nautilus-file.c
@@ -8100,10 +8101,12 @@ nautilus_file_is_remote (NautilusFile *file)
if (nautilus_file_get_filesystem_remote (file))
{
+ g_print("Filesystem for %s remote\n", nautilus_file_get_uri(file));
return TRUE;
}
filesystem_type = nautilus_file_get_filesystem_type (file);
+ g_print("Filesystem type of %s: %s\n",nautilus_file_get_uri(file),filesystem_type);
return filesystem_type != NULL && g_strv_contains (remote_types, filesystem_type);
}
File system info is fetched later in case you open nautilus on a directory: nautilus /media/$USER/foo-remote-path
or if you change the directory using the headerbar location path
So you get:
Filesystem type of file:///tmp/VM-TREE: (null)
Filesystem type of file:///tmp/VM-TREE: (null)
GOT FILE SYSTEM INFO file:///tmp/VM-TREE
Edited by Marco Trevisan