mercurial/merge.py
changeset 4819 9797124581c9
parent 4748 8808ea7da86b
child 4884 931f901ab811
equal deleted inserted replaced
4748:8808ea7da86b 4819:9797124581c9
   476                 repo.dirstate.update([fd], 'n', st_size=-1, st_mtime=-1)
   476                 repo.dirstate.update([fd], 'n', st_size=-1, st_mtime=-1)
   477                 if move:
   477                 if move:
   478                     repo.dirstate.forget([f])
   478                     repo.dirstate.forget([f])
   479         elif m == "d": # directory rename
   479         elif m == "d": # directory rename
   480             f2, fd, flag = a[2:]
   480             f2, fd, flag = a[2:]
       
   481             if not f2 and f not in repo.dirstate:
       
   482                 # untracked file moved
       
   483                 continue
   481             if branchmerge:
   484             if branchmerge:
   482                 repo.dirstate.update([fd], 'a')
   485                 repo.dirstate.update([fd], 'a')
   483                 if f:
   486                 if f:
   484                     repo.dirstate.update([f], 'r')
   487                     repo.dirstate.update([f], 'r')
   485                     repo.dirstate.copy(f, fd)
   488                     repo.dirstate.copy(f, fd)