diff --git a/trunk/rdiff-backup/TODO b/trunk/rdiff-backup/TODO index d3b1a217cab3e43cfe4815d5e7aac5fe003eaec0..1ae8741008da830857ac10140b7f5ba7767e639a 100644 --- a/trunk/rdiff-backup/TODO +++ b/trunk/rdiff-backup/TODO @@ -1,3 +1,7 @@ +Only warn, not abort, when get undefined metadata field + +Fix restore with --force over existing regular file. + For comparing, check source filesystem's abilities Clean up compare reports diff --git a/trunk/rdiff-backup/rdiff_backup/compare.py b/trunk/rdiff-backup/rdiff_backup/compare.py index 0679b22ac749ed1d8477c8a7bb83d86ce97b1fe9..892cf75106e8906f506037ec5b9b7a1df16ddabe 100644 --- a/trunk/rdiff-backup/rdiff_backup/compare.py +++ b/trunk/rdiff-backup/rdiff_backup/compare.py @@ -84,7 +84,7 @@ def Verify(mirror_rp, inc_rp, verify_time): "perhaps because these feature was added in v1.1.1" % (repo_rorp.get_indexpath(),), 2) continue - fp = RepoSide.rf_cache.get_fp(base_index + repo_rorp.index) + fp = RepoSide.rf_cache.get_fp(base_index + repo_rorp.index, repo_rorp) computed_hash = hash.compute_sha1_fp(fp) if computed_hash == repo_rorp.get_sha1(): log.Log("Verified SHA1 digest of " + repo_rorp.get_indexpath(), 5) @@ -174,7 +174,8 @@ class RepoSide(restore.MirrorStruct): continue # They must be equal, nothing else to check if (src_rorp.isreg() and mir_rorp.isreg() and src_rorp.getsize() == mir_rorp.getsize()): - mir_rorp.setfile(cls.rf_cache.get_fp(base_index + index)) + fp = cls.rf_cache.get_fp(base_index + index, mir_rorp) + mir_rorp.setfile(fp) mir_rorp.set_attached_filetype('snapshot') if mir_rorp: yield mir_rorp @@ -199,7 +200,7 @@ class DataSide(backup.SourceStruct): """Return 0 if their data hashes same, 1 otherwise""" if not mir_rorp.has_sha1(): log.Log("Warning: Metadata file has no digest for %s, " - "unable to compare." % (index,), 2) + "unable to compare." % (mir_rorp.get_indexpath(),), 2) return 0 elif (src_rp.getsize() == mir_rorp.getsize() and hash.compute_sha1(src_rp) == mir_rorp.get_sha1()):