/[smecontribs]/rpms/rdiff-backup/contribs7/rdiff-backup-1.1.7-fsabilites-symlinks.patch
ViewVC logotype

Contents of /rpms/rdiff-backup/contribs7/rdiff-backup-1.1.7-fsabilites-symlinks.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.3 - (show annotations) (download)
Tue Nov 25 16:20:15 2008 UTC (15 years, 5 months ago) by slords
Branch: MAIN
CVS Tags: HEAD
Changes since 1.2: +0 -0 lines
Restore

1 diff -Nur -x '*.orig' -x '*.rej' rdiff-backup-1.1.7/rdiff_backup/fs_abilities.py mezzanine_patched_rdiff-backup-1.1.7/rdiff_backup/fs_abilities.py
2 --- rdiff-backup-1.1.7/rdiff_backup/fs_abilities.py 2006-11-12 20:08:42.000000000 -0700
3 +++ mezzanine_patched_rdiff-backup-1.1.7/rdiff_backup/fs_abilities.py 2006-11-20 00:01:59.000000000 -0700
4 @@ -39,6 +39,7 @@
5 acls = None # True if access control lists supported
6 eas = None # True if extended attributes supported
7 hardlinks = None # True if hard linking supported
8 + symlinks = None # True if symbolic linking supported
9 fsync_dirs = None # True if directories can be fsync'd
10 dir_inc_perms = None # True if regular files can have full permissions
11 resource_forks = None # True if system supports resource forks
12 @@ -83,6 +84,7 @@
13 if not self.read_only:
14 add_boolean_list([('Ownership changing', self.ownership),
15 ('Hard linking', self.hardlinks),
16 + ('Symbolic linking', self.symlinks),
17 ('fsync() directories', self.fsync_dirs),
18 ('Directory inc permissions',
19 self.dir_inc_perms),
20 @@ -138,6 +140,7 @@
21 self.set_case_sensitive_readwrite(subdir)
22 self.set_ownership(subdir)
23 self.set_hardlinks(subdir)
24 + self.set_symlinks(subdir)
25 self.set_fsync_dirs(subdir)
26 self.set_eas(subdir, 1)
27 self.set_acls(subdir)
28 @@ -178,6 +181,19 @@
29 self.hardlinks = 0
30 else: self.hardlinks = 1
31
32 + def set_symlinks(self, testdir):
33 + """Set self.symlinks to true iff symbolic links can be made"""
34 + sl_target = testdir.append("symlink_target")
35 + sl_target.touch();
36 + sl_source = testdir.append("symlink_source")
37 + try:
38 + sl_source.symlink(sl_target.path)
39 + except (IOError, OSError):
40 + log.Log("Warning: symbolic links not supported by filesystem "
41 + "at %s" % (self.root_rp.path,), 3)
42 + self.symlinks = 0
43 + else: self.symlinks = 1
44 +
45 def set_fsync_dirs(self, testdir):
46 """Set self.fsync_dirs if directories can be fsync'd"""
47 assert testdir.conn is Globals.local_connection

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed