Mercurial > public > mercurial-scm > hg-stable
diff mercurial/scmutil.py @ 18466:ac0c12123743 stable
log: remove any ancestors of nullrev (issue3772)
For the special case, ":null" we remove the implied revision 0 since that
wouldn't make any sense here. A test case is added to make sure only nullrev is
shown.
author | Sean Farley <sean.michael.farley@gmail.com> |
---|---|
date | Wed, 23 Jan 2013 00:12:52 -0600 |
parents | 4f9a52858512 |
children | eb95cf4e219d 227479f61db9 |
line wrap: on
line diff
--- a/mercurial/scmutil.py Tue Jan 22 18:40:23 2013 -0600 +++ b/mercurial/scmutil.py Wed Jan 23 00:12:52 2013 -0600 @@ -6,6 +6,7 @@ # GNU General Public License version 2 or any later version. from i18n import _ +from mercurial.node import nullrev import util, error, osutil, revset, similar, encoding, phases import match as matchmod import os, errno, re, stat, sys, glob @@ -647,6 +648,8 @@ start, end = spec.split(_revrangesep, 1) start = revfix(repo, start, 0) end = revfix(repo, end, len(repo) - 1) + if end == nullrev and start <= 0: + start = nullrev rangeiter = repo.changelog.revs(start, end) if not seen and not l: # by far the most common case: revs = ["-1:0"]