diff -r df7ad90edbd4 -r 5a3979529740 mercurial/copies.py --- a/mercurial/copies.py Thu Apr 18 00:05:05 2019 -0700 +++ b/mercurial/copies.py Thu Apr 18 00:12:56 2019 -0700 @@ -134,7 +134,7 @@ if t[v] != k: # file wasn't renamed back to itself (i.e. case 4, not 3) t[k] = t[v] - if v in src: + elif v in src: # file is a copy of an existing file, i.e. case 6. t[k] = v