diff options
Diffstat (limited to 'Tools')
-rwxr-xr-x | Tools/scripts/ftpmirror.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Tools/scripts/ftpmirror.py b/Tools/scripts/ftpmirror.py index 11b618f..f25864b 100755 --- a/Tools/scripts/ftpmirror.py +++ b/Tools/scripts/ftpmirror.py @@ -198,7 +198,11 @@ def mirrorsubdir(f, localdir): if fp1 != fp: fp1.close() try: - os.rename(tempname, fullname) + os.unlink(fullname) + except os.error: + pass # Ignore the error + try: + os.rename(tempname, fullname) except os.error, msg: print "Can't rename %s to %s: %s" % (tempname, fullname, |