Mercurial > public > mercurial-scm > hg
diff hgext/mq.py @ 16063:c36db39b3fee stable
mq: fix qnext when all remaining patches are guarded
When all remaining patches are guarded, qnext used to return the last of the
queue anyway.
author | Patrick Mezard <pmezard@gmail.com> |
---|---|
date | Fri, 03 Feb 2012 19:38:31 +0100 |
parents | 140b6282ac79 |
children | 7e5a281a082c |
line wrap: on
line diff
--- a/hgext/mq.py Fri Feb 03 19:23:13 2012 +0100 +++ b/hgext/mq.py Fri Feb 03 19:38:31 2012 +0100 @@ -1757,9 +1757,9 @@ for i in xrange(start, len(self.series)): p, reason = self.pushable(i) if p: - break + return i self.explainpushable(i) - return i + return len(self.series) if self.applied: p = self.applied[-1].name try: @@ -2205,7 +2205,7 @@ @command("qnext", seriesopts, _('hg qnext [-s]')) def next(ui, repo, **opts): - """print the name of the next patch + """print the name of the next pushable patch Returns 0 on success.""" q = repo.mq