forked from TrueCloudLab/restic
fuse: Fix blob length cache
This commit is contained in:
parent
a66760d86d
commit
3883c7a190
1 changed files with 1 additions and 1 deletions
|
@ -15,7 +15,7 @@ type BlobSizeCache struct {
|
||||||
func NewBlobSizeCache(ctx context.Context, idx restic.Index) *BlobSizeCache {
|
func NewBlobSizeCache(ctx context.Context, idx restic.Index) *BlobSizeCache {
|
||||||
m := make(map[restic.ID]uint, 1000)
|
m := make(map[restic.ID]uint, 1000)
|
||||||
for pb := range idx.Each(ctx) {
|
for pb := range idx.Each(ctx) {
|
||||||
m[pb.ID] = pb.Length
|
m[pb.ID] = uint(restic.PlaintextLength(int(pb.Length)))
|
||||||
}
|
}
|
||||||
return &BlobSizeCache{
|
return &BlobSizeCache{
|
||||||
m: m,
|
m: m,
|
||||||
|
|
Loading…
Reference in a new issue