changeset 18477:010d6d3fcfee stable

hgweb: fetch tipmost unfiltered rev thru the changelog This fixes a traceback when tip is filtered (e.g. because it's secret). See issue3783, for which this is a partial fix.
author Kevin Bullock <kbullock@ringworld.org>
date Fri, 25 Jan 2013 14:50:18 -0600
parents 1fb9890c55bd
children 886936ecc21b
files mercurial/hgweb/webcommands.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/hgweb/webcommands.py	Fri Jan 25 16:11:16 2013 -0600
+++ b/mercurial/hgweb/webcommands.py	Fri Jan 25 14:50:18 2013 -0600
@@ -188,7 +188,7 @@
         if 'rev' in req.form:
             hi = req.form['rev'][0]
         else:
-            hi = len(web.repo) - 1
+            hi = 'tip'
         try:
             ctx = web.repo[hi]
         except error.RepoError: