log --copies: use manifest.find instead of delta when manifest parent is not rev-1
authorBrendan Cully <brendan@kublai.com>
Fri, 13 Oct 2006 09:58:55 -0700
changeset 3384 5e6c19919741
parent 3383 c7c6f1a45348
child 3385 9e834d039681
log --copies: use manifest.find instead of delta when manifest parent is not rev-1 This fixes issue391.
mercurial/commands.py
--- a/mercurial/commands.py	Fri Oct 13 09:58:55 2006 -0700
+++ b/mercurial/commands.py	Fri Oct 13 09:58:55 2006 -0700
@@ -1840,6 +1840,8 @@
                     break
         if rev in rcache[fn]:
             return rcache[fn][rev]
+        if repo.manifest.parentrevs(rev) != (rev - 1, -1):
+            return ncache[fn].get(repo.manifest.find(man, fn)[0])
         if not dcache or dcache[0] != man:
             dcache[:] = [man, repo.manifest.readdelta(man)]
         if fn in dcache[1]: