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

quatrix: fix incorrect modtime after uploading a file

Nick Craig-Wood449397b8df9d
diff --git a/backend/quatrix/quatrix.go b/backend/quatrix/quatrix.go
index 19d6f0119..f11cf470b 100644
--- a/backend/quatrix/quatrix.go
+++ b/backend/quatrix/quatrix.go
@@ -1151,7 +1151,10 @@ func (o *Object) dynamicUpload(ctx context.Context, size int64, modTime time.Tim
}
o.size = size
- o.modTime = modTime
+ // finalize sends the modtime rounded to microseconds so round
+ // here too to keep the in-memory modtime identical to the one a
+ // fresh listing returns.
+ o.modTime = modTime.Round(time.Microsecond)
return nil
}