hgext/graphlog.py
branchstable
changeset 10084 4c844f16bf39
parent 9631 1c34fca5d785
child 10097 ffa6f2eb934e
--- a/hgext/graphlog.py	Wed Dec 16 12:10:21 2009 +0100
+++ b/hgext/graphlog.py	Fri Dec 11 15:25:33 2009 +0900
@@ -241,15 +241,15 @@
     check_unsupported_flags(opts)
     limit = cmdutil.loglimit(opts)
     start, stop = get_revs(repo, opts["rev"])
-    stop = max(stop, start - limit + 1)
     if start == nullrev:
         return
 
     if path:
         path = util.canonpath(repo.root, os.getcwd(), path)
     if path: # could be reset in canonpath
-        revdag = graphmod.filerevs(repo, path, start, stop)
+        revdag = graphmod.filerevs(repo, path, start, stop, limit)
     else:
+        stop = max(stop, start - limit + 1)
         revdag = graphmod.revisions(repo, start, stop)
 
     displayer = show_changeset(ui, repo, opts, buffered=True)