From 68055e1e263695276a439b440d4f390f60f59b11 Mon Sep 17 00:00:00 2001 From: owsla Date: Wed, 9 Jan 2008 19:19:25 +0000 Subject: Change high-bit permissions test to check files and directories. (Patch from Marc Horowitz) git-svn-id: http://svn.savannah.nongnu.org/svn/rdiff-backup/trunk@872 2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109 --- rdiff-backup/CHANGELOG | 4 ++++ rdiff-backup/rdiff_backup/fs_abilities.py | 15 ++++++++++----- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/rdiff-backup/CHANGELOG b/rdiff-backup/CHANGELOG index d95f507..3792c1a 100644 --- a/rdiff-backup/CHANGELOG +++ b/rdiff-backup/CHANGELOG @@ -1,6 +1,10 @@ New in v1.1.16 (????/??/??) --------------------------- +Change high-bit permissions test to check both files and directories. +Improves rdiff-backup's support for AFS and closes Debian bug #450409. +(Patch from Marc Horowitz) + rdiff-backup-statistics now supports quoted repositories. Closes Savannah bug #21813. (Andrew Ferguson) diff --git a/rdiff-backup/rdiff_backup/fs_abilities.py b/rdiff-backup/rdiff_backup/fs_abilities.py index b028369..a45a8f9 100644 --- a/rdiff-backup/rdiff_backup/fs_abilities.py +++ b/rdiff-backup/rdiff_backup/fs_abilities.py @@ -439,14 +439,19 @@ class FSAbilities: def set_high_perms_readwrite(self, dir_rp): """Test for writing high-bit permissions like suid""" - tmp_rp = dir_rp.append("high_perms") - tmp_rp.touch() + tmpf_rp = dir_rp.append("high_perms_file") + tmpf_rp.touch() + tmpd_rp = dir_rp.append("high_perms_dir") + tmpd_rp.touch() try: - tmp_rp.chmod(07000) - tmp_rp.chmod(07777) + tmpf_rp.chmod(07000) + tmpf_rp.chmod(07777) + tmpd_rp.chmod(07000) + tmpd_rp.chmod(07777) except (OSError, IOError): self.high_perms = 0 else: self.high_perms = 1 - tmp_rp.delete() + tmpf_rp.delete() + tmpd_rp.delete() def set_symlink_perms(self, dir_rp): """Test if symlink permissions are affected by umask""" -- cgit v1.2.1