changeset 7283:b19c0200c90b

bookmarks: fix strip handling
author Benoit Boissinot <benoit.boissinot@ens-lyon.org>
date Tue, 28 Oct 2008 20:48:30 +0100
parents 6541696b5f66
children ac81ffac0f35
files hgext/bookmarks.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/bookmarks.py	Tue Oct 28 20:23:22 2008 +0100
+++ b/hgext/bookmarks.py	Tue Oct 28 20:48:30 2008 +0100
@@ -130,13 +130,13 @@
     srev = changelog.rev(node)
     tostrip = [srev]
     saveheads = []
-    for r in xrange(srev, changelog.rev(changelog.tip()) + 1):
+    for r in xrange(srev, len(changelog)):
         parents = changelog.parentrevs(r)
         if parents[0] in tostrip or parents[1] in tostrip:
             tostrip.append(r)
             if parents[1] != nullrev:
                 for p in parents:
-                    if p not in tostrip and p > striprev:
+                    if p not in tostrip and p > srev:
                         saveheads.append(p)
     return [r for r in tostrip if r not in saveheads]