From 3ac783ccd3d44979266ed81b0aea1d917465bdae Mon Sep 17 00:00:00 2001 From: bescoto Date: Mon, 12 Dec 2005 01:32:50 +0000 Subject: False negative ACL compare fix git-svn-id: http://svn.savannah.nongnu.org/svn/rdiff-backup/branches/r1-0@703 2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109 --- rdiff-backup/CHANGELOG | 7 +++++++ rdiff-backup/rdiff-backup.1 | 28 +++++++++++++++++++++++----- rdiff-backup/rdiff_backup/eas_acls.py | 2 +- rdiff-backup/testing/eas_aclstest.py | 12 ++++++++++++ 4 files changed, 43 insertions(+), 6 deletions(-) diff --git a/rdiff-backup/CHANGELOG b/rdiff-backup/CHANGELOG index 9c8490b..da193e4 100644 --- a/rdiff-backup/CHANGELOG +++ b/rdiff-backup/CHANGELOG @@ -1,3 +1,10 @@ +New in v1.0.4 (????/??/??) +-------------------------- + +Files with ACLs will not be unnecessarily marked as changed (bug +report by Carsten Lorenz). + + New in v1.0.3 (2005/11/25) -------------------------- diff --git a/rdiff-backup/rdiff-backup.1 b/rdiff-backup/rdiff-backup.1 index 2c4ffeb..15e1c7d 100644 --- a/rdiff-backup/rdiff-backup.1 +++ b/rdiff-backup/rdiff-backup.1 @@ -139,6 +139,11 @@ same rules as and .B --exclude. .TP +.B --exclude-globbing-filelist-stdin +Like +.BR --exclude-globbing-filelist , +but the list of files will be read from standard input. +.TP .B --exclude-other-filesystems Exclude files on file systems (identified by device number) other than the file system the root of the source directory is on. @@ -206,6 +211,11 @@ same rules as and .B --exclude. .TP +.B --include-globbing-filelist-stdin +Like +.BR --include-globbing-filelist , +but the list of files will be read from standard input. +.TP .BI "--include-regexp " regexp Include files matching the regular expression .IR regexp . @@ -569,13 +579,21 @@ and easy-to-use. The file selection system comprises a number of file selection conditions, which are set using one of the following command line options: -.BR --exclude , --exclude-filelist , -.BR --exclude-device-files , --exclude-fifos , -.BR --exclude-sockets , --exclude-symbolic-links , +.BR --exclude , +.BR --exclude-filelist , +.BR --exclude-device-files , +.BR --exclude-fifos , +.BR --exclude-sockets , +.BR --exclude-symbolic-links , .BR --exclude-globbing-filelist , -.BR --exclude-filelist-stdin , --exclude-regexp , --exclude-special-files , +.BR --exclude-globbing-filelist-stdin , +.BR --exclude-filelist-stdin , +.BR --exclude-regexp , +.BR --exclude-special-files , .BR --include , -.BR --include-filelist , --include-globbing-filelist , +.BR --include-filelist , +.BR --include-globbing-filelist , +.BR --include-globbing-filelist-stdin , .BR --include-filelist-stdin , and .BR --include-regexp . diff --git a/rdiff-backup/rdiff_backup/eas_acls.py b/rdiff-backup/rdiff_backup/eas_acls.py index 0db865f..a06ae97 100644 --- a/rdiff-backup/rdiff_backup/eas_acls.py +++ b/rdiff-backup/rdiff_backup/eas_acls.py @@ -282,7 +282,7 @@ class AccessControlLists: def cmp_entry_list(self, l1, l2): """True if the lists have same entries. Assume preordered""" - if not l1: return l1 == l2 + if not l1: return not l2 if not l2 or len(l1) != len(l2): return 0 for i in range(len(l1)): type1, namepair1, perms1 = l1[i] diff --git a/rdiff-backup/testing/eas_aclstest.py b/rdiff-backup/testing/eas_aclstest.py index 4d6535f..b502a19 100644 --- a/rdiff-backup/testing/eas_aclstest.py +++ b/rdiff-backup/testing/eas_aclstest.py @@ -495,6 +495,18 @@ other::---""") else: assert 0, "Above should have exited with fatal error" Globals.never_drop_acls = None + def test_nochange(self): + """Make sure files with ACLs not unnecessarily flagged changed""" + self.make_temp() + self.make_backup_dirs() + rdiff_backup(1, 1, self.acl_testdir1.path, tempdir.path, + current_time = 10000) + rdiff_backup(1, 1, self.acl_testdir1.path, tempdir.path, + current_time = 20000) + incdir = tempdir.append('rdiff-backup-data').append('increments') + assert incdir.isdir(), incdir + assert not incdir.listdir(), incdir.listdir() + class CombinedTest(unittest.TestCase): """Test backing up and restoring directories with both EAs and ACLs""" -- cgit v1.2.1