Commit 378e738e authored by owsla's avatar owsla

Properly pickle QuotedRPaths


git-svn-id: http://svn.savannah.nongnu.org/svn/rdiff-backup@840 2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109
parent c1b32ebb
New in v1.1.13 (????/??/??)
---------------------------
Properly pickle QuotedRPaths. Fixes regress operation on quoted filesystems.
Closes Savannah bug #20570 reported by Morgan Read. (Andrew Ferguson)
Warn if can't write extended attribute. (Andrew Ferguson)
Gracefully handle situations where rdiff-backup tries to set the sticky
......
......@@ -126,6 +126,13 @@ class QuotedRPath(rpath.RPath):
rpath.RPath.__init__(self, connection, base, self.quoted_index, data)
self.index = index
def __setstate__(self, rpath_state):
"""Reproduce QuotedRPath from __getstate__ output"""
conn_number, self.base, self.index, self.data = rpath_state
self.conn = Globals.connection_dict[conn_number]
self.quoted_index = tuple(map(quote, self.index))
self.path = "/".join((self.base,) + self.quoted_index)
def listdir(self):
"""Return list of unquoted filenames in current directory
......
......@@ -345,7 +345,7 @@ def check_pids(curmir_incs):
try: os.kill(pid, 0)
except OSError, exc:
if exc[0] == errno.ESRCH: return 0
else: Log("Warning: unable to check if PID %d still running" % (pid,), 2)
else: log.Log("Warning: unable to check if PID %d still running" % (pid,), 2)
return 1
for curmir_rp in curmir_incs:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment