2
2
mirror of https://github.com/octoleo/restic.git synced 2024-11-02 03:42:31 +00:00

fuse: Fix blob length cache

This commit is contained in:
Alexander Neumann 2017-06-18 16:28:39 +02:00
parent a66760d86d
commit 3883c7a190

View File

@ -15,7 +15,7 @@ type BlobSizeCache struct {
func NewBlobSizeCache(ctx context.Context, idx restic.Index) *BlobSizeCache {
m := make(map[restic.ID]uint, 1000)
for pb := range idx.Each(ctx) {
m[pb.ID] = pb.Length
m[pb.ID] = uint(restic.PlaintextLength(int(pb.Length)))
}
return &BlobSizeCache{
m: m,