"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files
Go azure-blobazure-blob-storageazure-filesbackblaze-b2cloud-storagedropboxencryptionftpfuse-filesystemgogolanggoogle-cloud-storagegoogle-driveonedriveopenstack-swiftrclones3sftpsyncwebdav
filen: fix 32 bit targets not being able to list directories Fixes #9142
Endurieled5bd327c08b
diff --git a/backend/filen/filen.go b/backend/filen/filen.goindex 57d992404..72095d39d 100644--- a/backend/filen/filen.go+++ b/backend/filen/filen.go@@ -355,19 +355,19 @@ type chunkWriter struct {chunkSize int64chunksLock sync.Mutex- knownChunks map[int][]byte // known chunks to be hashed- nextChunkToHash int+ knownChunks map[int64][]byte // known chunks to be hashed+ nextChunkToHash int64sizeLock sync.Mutexsize int64}func (cw *chunkWriter) WriteChunk(ctx context.Context, chunkNumber int, reader io.ReadSeeker) (bytesWritten int64, err error) {- realChunkNumber := int(int64(chunkNumber) * (cw.chunkSize) / sdk.ChunkSize)+ realChunkNumber := int64(chunkNumber) * (cw.chunkSize) / sdk.ChunkSizechunk := make([]byte, sdk.ChunkSize, sdk.ChunkSize+cw.EncryptionKey.Cipher.Overhead())totalWritten := int64(0)- for sliceStart := 0; sliceStart < int(cw.chunkSize); sliceStart += sdk.ChunkSize {+ for sliceStart := int64(0); sliceStart < cw.chunkSize; sliceStart += sdk.ChunkSize {chunk = chunk[:sdk.ChunkSize]chunkRead := 0for {@@ -496,7 +496,7 @@ func (f *Fs) OpenChunkWriter(ctx context.Context, remote string, src fs.ObjectInfilen: f.filen,chunkSize: chunkSize,bucketAndRegion: make(chan client.V3UploadResponse, 1),- knownChunks: make(map[int][]byte),+ knownChunks: make(map[int64][]byte),nextChunkToHash: 0,size: 0,}, nil@@ -1122,8 +1122,8 @@ func (f *Fs) About(ctx context.Context) (*fs.Usage, error) {return nil, err}- total := int64(userInfo.MaxStorage)- used := int64(userInfo.UsedStorage)+ total := userInfo.MaxStorage+ used := userInfo.UsedStoragefree := total - usedreturn &fs.Usage{Total: &total,diff --git a/go.mod b/go.modindex 27ee6b8b8..17e88ee57 100644--- a/go.mod+++ b/go.mod@@ -11,7 +11,7 @@ require (github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.6.3github.com/Azure/azure-sdk-for-go/sdk/storage/azfile v1.5.3github.com/Azure/go-ntlmssp v0.0.2-0.20251110135918-10b7b7e7cd26- github.com/FilenCloudDienste/filen-sdk-go v0.0.35+ github.com/FilenCloudDienste/filen-sdk-go v0.0.37github.com/Files-com/files-sdk-go/v3 v3.2.264github.com/Max-Sum/base32768 v0.0.0-20230304063302-18e6ce5945fdgithub.com/a1ex3/zstd-seekable-format-go/pkg v0.10.0diff --git a/go.sum b/go.sumindex 5b41ee1cc..e765a00f9 100644--- a/go.sum+++ b/go.sum@@ -61,8 +61,8 @@ github.com/AzureAD/microsoft-authentication-library-for-go v1.6.0 h1:XRzhVemXdgvgithub.com/AzureAD/microsoft-authentication-library-for-go v1.6.0/go.mod h1:HKpQxkWaGLJ+D/5H8QRpyQXA1eKjxkFlOMwck5+33Jk=github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=-github.com/FilenCloudDienste/filen-sdk-go v0.0.35 h1:geuYpD/1ZXSp1H3kdW7si+KRUIrHHqM1kk8lqoA8Y9M=-github.com/FilenCloudDienste/filen-sdk-go v0.0.35/go.mod h1:0cBhKXQg49XbKZZfk5TCDa3sVLP+xMxZTWL+7KY0XR0=+github.com/FilenCloudDienste/filen-sdk-go v0.0.37 h1:W8S9TrAyZ4//3PXsU6+Bi+fe/6uIL986GyS7PVzIDL4=+github.com/FilenCloudDienste/filen-sdk-go v0.0.37/go.mod h1:0cBhKXQg49XbKZZfk5TCDa3sVLP+xMxZTWL+7KY0XR0=github.com/Files-com/files-sdk-go/v3 v3.2.264 h1:lMHTplAYI9FtmCo/QOcpRxmPA5REVAct1r2riQmDQKw=github.com/Files-com/files-sdk-go/v3 v3.2.264/go.mod h1:wGqkOzRu/ClJibvDgcfuJNAqI2nLhe8g91tPlDKRCdE=github.com/IBM/go-sdk-core/v5 v5.18.5 h1:g0JRl3sYXJczB/yuDlrN6x22LJ6jIxhp0Sa4ARNW60c=