diff options
author | ignapk <automat.script@gmail.com> | 2020-07-12 20:49:01 +0200 |
---|---|---|
committer | ignapk <automat.script@gmail.com> | 2020-07-13 16:15:19 +0200 |
commit | c028e48e589d07360c7ea8939a7b334948ca0e0c (patch) | |
tree | cb983b0a708c1eb9ab49d57ea00cfd1facadde21 | |
parent | f03cb9f79a2f005326834dc082dfbae4e0a4b786 (diff) | |
download | nautilus-c028e48e589d07360c7ea8939a7b334948ca0e0c.tar.gz |
file-operations: auto-escape filenames on fuseblk mounts
Currently when copying files that have reserved characters in their
names to NTFS or exFAT filesystems mounted using FUSE, the process will fail.
The fuseblk filesystem type could be of any type in theory, but in
practice is usually NTFS or exFAT, so make the assumption in pragmatic
way to solve this issue.
Closes #1343
-rw-r--r-- | src/nautilus-file-operations.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/nautilus-file-operations.c b/src/nautilus-file-operations.c index 4e8e0224c..3f98caedd 100644 --- a/src/nautilus-file-operations.c +++ b/src/nautilus-file-operations.c @@ -4214,6 +4214,11 @@ make_file_name_valid_for_dest_fs (char *filename, { if (!strcmp (dest_fs_type, "fat") || !strcmp (dest_fs_type, "vfat") || + /* The fuseblk filesystem type could be of any type + * in theory, but in practice is usually NTFS or exFAT. + * This assumption is a pragmatic way to solve + * https://gitlab.gnome.org/GNOME/nautilus/-/issues/1343 */ + !strcmp (dest_fs_type, "fuse") || !strcmp (dest_fs_type, "ntfs") || !strcmp (dest_fs_type, "msdos") || !strcmp (dest_fs_type, "msdosfs")) |