diff mercurial/manifest.py @ 11962:5f7ee3db3dd8

revlog._addrevision(): make the parent of the cached delta explicit
author Benoit Boissinot <benoit.boissinot@ens-lyon.org>
date Wed, 18 Aug 2010 19:45:52 +0200
parents cf858e76e992
children f38b0a3308b6
line wrap: on
line diff
--- a/mercurial/manifest.py	Thu Aug 19 13:25:46 2010 +0200
+++ b/mercurial/manifest.py	Wed Aug 18 19:45:52 2010 +0200
@@ -188,11 +188,7 @@
             if dstart != None:
                 delta.append([dstart, dend, "".join(dline)])
             # apply the delta to the addlist, and get a delta for addrevision
-            cachedelta = addlistdelta(addlist, delta)
-
-            # the delta is only valid if we've been processing the tip revision
-            if p1 != self.tip():
-                cachedelta = None
+            cachedelta = (self.rev(p1), addlistdelta(addlist, delta))
             arraytext = addlist
             text = buffer(arraytext)