diff options
author | bescoto <bescoto@2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109> | 2003-08-23 23:58:08 +0000 |
---|---|---|
committer | bescoto <bescoto@2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109> | 2003-08-23 23:58:08 +0000 |
commit | 188794d438954505a5c2effb74ddea5105b8b40e (patch) | |
tree | 0afc825adca627da6661f838e2863c65c2fef3a4 /rdiff-backup/rdiff_backup/increment.py | |
parent | 0cde1ef022765b5763cf68be308553460bcbaadb (diff) | |
download | rdiff-backup-188794d438954505a5c2effb74ddea5105b8b40e.tar.gz |
Mostly fixing unreadable reg root source/non-root dest bug
git-svn-id: http://svn.savannah.nongnu.org/svn/rdiff-backup/branches/r0-12@400 2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109
Diffstat (limited to 'rdiff-backup/rdiff_backup/increment.py')
-rw-r--r-- | rdiff-backup/rdiff_backup/increment.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/rdiff-backup/rdiff_backup/increment.py b/rdiff-backup/rdiff_backup/increment.py index ce6585c..d0341ef 100644 --- a/rdiff-backup/rdiff_backup/increment.py +++ b/rdiff-backup/rdiff_backup/increment.py @@ -79,7 +79,13 @@ def makediff(new, mirror, incpref): if compress: diff = get_inc(incpref, "diff.gz") else: diff = get_inc(incpref, "diff") - Rdiff.write_delta(new, mirror, diff, compress) + if Globals.process_uid != 0 and not new.readable(): + # Check for unreadable files + old_new_perms = new.getperms() + new.chmod(0400 | old_new_perms) + Rdiff.write_delta(new, mirror, diff, compress) + new.chmod(old_new_perms) + else: Rdiff.write_delta(new, mirror, diff, compress) rpath.copy_attribs(mirror, diff) return diff |