From 6bf433fed5a4d54b678315adbfd0439707bdd730 Mon Sep 17 00:00:00 2001 From: owsla Date: Fri, 26 Sep 2008 23:13:18 +0000 Subject: On Mac OS X, read the com.apple.FinderInfo extended attribute since it is the only storage location for the 'busy' (Z) Finder attribute. git-svn-id: http://svn.savannah.nongnu.org/svn/rdiff-backup/trunk@938 2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109 --- rdiff-backup/rdiff_backup/eas_acls.py | 5 ++--- rdiff-backup/rdiff_backup/rpath.py | 4 ++++ 2 files changed, 6 insertions(+), 3 deletions(-) (limited to 'rdiff-backup/rdiff_backup') diff --git a/rdiff-backup/rdiff_backup/eas_acls.py b/rdiff-backup/rdiff_backup/eas_acls.py index 856b700..af01c5e 100644 --- a/rdiff-backup/rdiff_backup/eas_acls.py +++ b/rdiff-backup/rdiff_backup/eas_acls.py @@ -68,9 +68,8 @@ class ExtendedAttributes: if attr.startswith('system.'): # Do not preserve system extended attributes continue - if not rp.isdir() and attr == 'com.apple.FinderInfo' or attr == 'com.apple.ResourceFork': - # FinderInfo and Resource Fork handled elsewhere, except - # for directories + if not rp.isdir() and attr == 'com.apple.ResourceFork': + # Resource Fork handled elsewhere, except for directories continue try: self.attr_dict[attr] = rp.conn.xattr.getxattr(rp.path, attr) except IOError, exc: diff --git a/rdiff-backup/rdiff_backup/rpath.py b/rdiff-backup/rdiff_backup/rpath.py index 0dadd43..8fd7d85 100644 --- a/rdiff-backup/rdiff_backup/rpath.py +++ b/rdiff-backup/rdiff_backup/rpath.py @@ -1455,6 +1455,10 @@ def setdata_local(rpath): def carbonfile_get(rpath): """Return carbonfile value for local rpath""" + # Note, after we drop support for Mac OS X 10.0 - 10.3, it will no longer + # be necessary to read the finderinfo struct since it is a strict subset + # of the data stored in the com.apple.FinderInfo extended attribute + # introduced in 10.4. Indeed, FSpGetFInfo() is deprecated on 10.4. from Carbon.File import FSSpec from Carbon.File import FSRef import Carbon.Files -- cgit v1.2.1