mirror of
https://github.com/borgbackup/borg.git
synced 2026-03-18 00:26:13 -04:00
file_integrity: hash_part: mix length into state
This commit is contained in:
parent
d463dd89aa
commit
83bca02a4e
1 changed files with 1 additions and 0 deletions
|
|
@ -152,6 +152,7 @@ class IntegrityCheckedFile(FileLikeWrapper):
|
|||
def hash_part(self, partname, is_final=False):
|
||||
if not self.writing and not self.digests:
|
||||
return
|
||||
self.hasher.update(('%10d' % len(partname)).encode())
|
||||
self.hasher.update(partname.encode())
|
||||
self.hasher.hash_length(seek_to_end=is_final)
|
||||
digest = self.hasher.hexdigest()
|
||||
|
|
|
|||
Loading…
Reference in a new issue