Commit cc9cb5d8 authored by bescoto's avatar bescoto

long directory name fix


git-svn-id: http://svn.savannah.nongnu.org/svn/rdiff-backup@715 2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109
parent f017e72b
......@@ -4,6 +4,9 @@ New in v1.0.4 (????/??/??)
Files with ACLs will not be unnecessarily marked as changed (bug
report by Carsten Lorenz).
Another fix for long-filenames crash, this time when a long-named
directory with files in it gets deleted
New in v1.0.3 (2005/11/25)
--------------------------
......
......@@ -584,7 +584,10 @@ class PatchITRB(rorpiter.ITRBranch):
rpath.copy_attribs(self.dir_update, self.base_rp)
else:
assert self.dir_replacement
self.base_rp.rmdir()
try: self.base_rp.rmdir()
except OSError:
log.Log("Warning: unable to rmdir " + self.base_rp.path, 2)
self.base_rp.delete()
if self.dir_replacement.lstat():
rpath.rename(self.dir_replacement, self.base_rp)
......
......@@ -159,6 +159,7 @@ class IncrementTest1(unittest.TestCase):
Myrm(Local.rpout.path)
InternalBackup(1, 1, "testfiles/longfilenames1", Local.rpout.path, 100)
InternalBackup(1, 1, "testfiles/longfilenames2", Local.rpout.path, 200)
InternalBackup(1, 1, "testfiles/empty", Local.rpout.path, 300)
def test_quoted_hardlinks(self):
"""Test backing up a directory with quoted hardlinks in it"""
......
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