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

ulozto: Fix handling of root paths with leading / trailing slashes.

IoT Maestroc5ff5afc21e8
diff --git a/backend/ulozto/ulozto.go b/backend/ulozto/ulozto.go
index 063f465db..1cdeefd74 100644
--- a/backend/ulozto/ulozto.go
+++ b/backend/ulozto/ulozto.go
@@ -121,6 +121,9 @@ func NewFs(ctx context.Context, name, root string, m configmap.Mapper) (fs.Fs, e
return nil, err
}
+ // Strip leading and trailing slashes, see https://github.com/rclone/rclone/issues/7796 for details.
+ root = strings.Trim(root, "/")
+
client := fshttp.NewClient(ctx)
f := &Fs{