Mercurial > hg-stable
changeset 19491:e111d5e6bbbd stable
hgweb: fix duplication for some search queries
Given that N is maximum revision number in a repo, than if a revision with
number N-100n or N-100n+1 (for any integer n) is found with a hgweb search,
this revision is duplicated in search results.
author | Alexander Plavin <me@aplavin.ru> |
---|---|
date | Sun, 21 Jul 2013 01:38:04 +0400 |
parents | 074bd02352c0 |
children | dfc0fe1541d9 |
files | mercurial/hgweb/webcommands.py |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/hgweb/webcommands.py Wed Jul 24 14:51:13 2013 -0400 +++ b/mercurial/hgweb/webcommands.py Sun Jul 21 01:38:04 2013 +0400 @@ -119,7 +119,7 @@ cl = web.repo.changelog for i in xrange(len(web.repo) - 1, 0, -100): l = [] - for j in cl.revs(max(0, i - 100), i + 1): + for j in cl.revs(max(0, i - 99), i): ctx = web.repo[j] l.append(ctx) l.reverse()