Merge pull request #1549 from MJDSys/more_index_lookup_avoids

More optimizations to avoid calling Index.Lookup()
This commit is contained in:
Alexander Neumann
2018-01-24 20:53:30 +01:00
17 changed files with 246 additions and 81 deletions

View File

@@ -87,8 +87,8 @@ func TestFuseFile(t *testing.T) {
memfile []byte
)
for _, id := range content {
size, err := repo.LookupBlobSize(id, restic.DataBlob)
rtest.OK(t, err)
size, found := repo.LookupBlobSize(id, restic.DataBlob)
rtest.Assert(t, found, "Expected to find blob id %v", id)
filesize += uint64(size)
buf := restic.NewBlobBuffer(int(size))