diff options
author | n-peugnet <n.peugnet@free.fr> | 2021-09-21 18:16:24 +0200 |
---|---|---|
committer | n-peugnet <n.peugnet@free.fr> | 2021-09-21 18:16:24 +0200 |
commit | bb744d04d4bac4003072264a8696bf59ef884b16 (patch) | |
tree | 72492ecc2f712473bdbec726d9adf93644ff3ad3 /repo.go | |
parent | 91bdaf7ffa76dee079a07fd54fcaf1d0f84428f0 (diff) | |
download | dna-backup-bb744d04d4bac4003072264a8696bf59ef884b16.tar.gz dna-backup-bb744d04d4bac4003072264a8696bf59ef884b16.zip |
fix same delta chunk is not found on second commit
Diffstat (limited to 'repo.go')
-rw-r--r-- | repo.go | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -582,7 +582,7 @@ func (r *Repo) matchStream(stream io.Reader, version int) []Chunk { h := hasher.Sum64() chunkId, exists := r.fingerprints[h] if exists { - if len(buff) > r.chunkSize && len(buff) < r.chunkSize*2 { + if len(buff) > r.chunkSize && len(buff) <= r.chunkSize*2 { size := len(buff) - r.chunkSize temp := NewTempChunk(buff[:size]) chunks = append(chunks, r.encodeTempChunks(prev, temp, version, &last, storeQueue)...) |