Skip to content

"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files

cmount: fix on Linux - only apply volname for Windows and macOS

Nick Craig-Wood84e21ade6b7a
diff --git a/cmd/cmount/mount.go b/cmd/cmount/mount.go
index 2a947aa77..3bb26ebe2 100644
--- a/cmd/cmount/mount.go
+++ b/cmd/cmount/mount.go
@@ -69,8 +69,10 @@ func mountOptions(device string, mountpoint string) (options []string) {
options = append(options, "--FileSystemName=rclone")
}
- if mountlib.VolumeName != "" {
- options = append(options, "-o", "volname="+mountlib.VolumeName)
+ if runtime.GOOS == "darwin" || runtime.GOOS == "windows" {
+ if mountlib.VolumeName != "" {
+ options = append(options, "-o", "volname="+mountlib.VolumeName)
+ }
}
if mountlib.AllowNonEmpty {
options = append(options, "-o", "nonempty")