diff -r d5011e347476 -r bb70d5fa02ae mercurial/merge.py --- a/mercurial/merge.py Mon Feb 26 12:12:29 2007 -0600 +++ b/mercurial/merge.py Tue Feb 27 16:47:16 2007 -0600 @@ -184,7 +184,7 @@ invalid[dsrc] = True del dirmove[dsrc] else: - dirmove[dsrc] = ddst + dirmove[dsrc + "/"] = ddst + "/" del d1, d2, invalid @@ -194,9 +194,10 @@ # check unaccounted nonoverlapping files for f in u1 + u2: if f not in fullcopy: - d = os.path.dirname(f) - if d in dirmove: - copy[f] = dirmove[d] + "/" + os.path.basename(f) + for d in dirmove: + if f.startswith(d): + copy[f] = dirmove[d] + f[len(d):] + break return copy