changeset 1765:b9fac31f34c9

hg log --limit shouldn't count unprinted revisions (found by TK Soh)
author Thomas Arendsen Hein <thomas@intevation.de>
date Tue, 21 Feb 2006 15:54:50 +0100
parents 4671078dbfe7
children 982fb022a16a
files mercurial/commands.py
diffstat 1 files changed, 4 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/commands.py	Tue Feb 21 15:37:23 2006 +0100
+++ b/mercurial/commands.py	Tue Feb 21 15:54:50 2006 +0100
@@ -1660,9 +1660,10 @@
                 du.write("\n\n")
         elif st == 'iter':
             if count == limit: break
-            count += 1
-            for args in du.hunk[rev]:
-                ui.write(*args)
+            if du.hunk[rev]:
+                count += 1
+                for args in du.hunk[rev]:
+                    ui.write(*args)
 
 def manifest(ui, repo, rev=None):
     """output the latest or given revision of the project manifest