mercurial/copies.py
changeset 46650 2803f94b7431
parent 46649 324ded1aa2ab
child 46819 d4ba4d51f85f
--- a/mercurial/copies.py	Fri Mar 05 14:26:56 2021 -0800
+++ b/mercurial/copies.py	Thu Mar 04 08:20:19 2021 -0800
@@ -763,6 +763,11 @@
             base = x
         x_copies = _forwardcopies(a, x)
         y_copies = _forwardcopies(a, y, base, match=match)
+        same_keys = set(x_copies) & set(y_copies)
+        for k in same_keys:
+            if x_copies.get(k) == y_copies.get(k):
+                del x_copies[k]
+                del y_copies[k]
         x_backward_renames = _reverse_renames(x_copies, x, match)
         copies = _chain(
             x_backward_renames,