merge: fix a bug where copies were getting ignored
authorMatt Mackall <mpm@selenic.com>
Thu, 05 Apr 2007 16:25:47 -0500
changeset 4303 09c5f734ff6a
parent 4302 d69bdc1091b8
child 4305 5e05007d3857
child 4312 82be6af21697
merge: fix a bug where copies were getting ignored
mercurial/merge.py
--- a/mercurial/merge.py	Mon Apr 02 14:16:44 2007 -0500
+++ b/mercurial/merge.py	Thu Apr 05 16:25:47 2007 -0500
@@ -129,15 +129,15 @@
         '''check possible copies for filectx c'''
         for of in findold(c):
             if of not in man:
-                return
+                continue
             c2 = ctx(of, man[of])
             ca = c.ancestor(c2)
             if not ca: # unrelated
-                return
+                continue
             if ca.path() == c.path() or ca.path() == c2.path():
                 fullcopy[c.path()] = of
-                if c == ca or c2 == ca: # no merge needed, ignore copy
-                    return
+                if c == ca and c2 == ca: # no merge needed, ignore copy
+                    continue
                 copy[c.path()] = of
 
     def dirs(files):