localrepo: do not complain about missing journal files
authorAlain Leufroy <alain.leufroy@logilab.fr>
Mon, 16 Apr 2012 10:56:37 +0200
changeset 16441 9dd10a574af2
parent 16440 692bf06bb1af
child 16442 9181188ffb5b
localrepo: do not complain about missing journal files
mercurial/localrepo.py
--- a/mercurial/localrepo.py	Mon Apr 16 10:33:18 2012 +0200
+++ b/mercurial/localrepo.py	Mon Apr 16 10:56:37 2012 +0200
@@ -2329,7 +2329,10 @@
     renamefiles = [tuple(t) for t in files]
     def a():
         for src, dest in renamefiles:
-            util.rename(src, dest)
+            try:
+                util.rename(src, dest)
+            except OSError: # journal file does not yet exist
+                pass
     return a
 
 def undoname(fn):