mirror of
https://github.com/borgbackup/borg.git
synced 2025-02-15 02:46:31 +00:00
consider an empty file as different to a non-existing file, fixes #3688
This commit is contained in:
parent
01beee37a7
commit
c3b7d7b60c
1 changed files with 4 additions and 0 deletions
|
@ -1030,6 +1030,10 @@ def compare_link(item1, item2):
|
||||||
return 'changed link'
|
return 'changed link'
|
||||||
|
|
||||||
def contents_changed(item1, item2):
|
def contents_changed(item1, item2):
|
||||||
|
if item1.get('deleted') != item2.get('deleted'):
|
||||||
|
# a deleleted/non-existing file is considered different to an existing file,
|
||||||
|
# even if the latter is empty.
|
||||||
|
return True
|
||||||
if can_compare_chunk_ids:
|
if can_compare_chunk_ids:
|
||||||
return item1.chunks != item2.chunks
|
return item1.chunks != item2.chunks
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue