scanner: Allow disabling weak hash in scanning (fixes #3891)
GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/3905
This commit is contained in:
committed by
Jakob Borg
parent
bd55ec79d2
commit
dd78177ae0
@@ -1082,7 +1082,7 @@ func (f *sendReceiveFolder) handleFile(file protocol.FileInfo, copyChan chan<- c
|
||||
|
||||
// Check for an old temporary file which might have some blocks we could
|
||||
// reuse.
|
||||
tempBlocks, err := scanner.HashFile(tempName, protocol.BlockSize, nil)
|
||||
tempBlocks, err := scanner.HashFile(tempName, protocol.BlockSize, nil, false)
|
||||
if err == nil {
|
||||
// Check for any reusable blocks in the temp file
|
||||
tempCopyBlocks, _ := scanner.BlockDiff(tempBlocks, file.Blocks)
|
||||
|
||||
Reference in New Issue
Block a user