Merge with crew
authorMatt Mackall <mpm@selenic.com>
Sun, 15 Apr 2007 18:40:22 -0500
changeset 4345 9bfe93edfbb0
parent 4344 26a2fa9433b8 (diff)
parent 4338 7ae02bce8de2 (current diff)
child 4346 c593e502f7fd
child 4348 b633f470944e
Merge with crew
--- a/mercurial/hgweb/hgweb_mod.py
+++ b/mercurial/hgweb/hgweb_mod.py
@@ -716,7 +716,7 @@ class hgweb(object):
                     # strip leading /
                     pi = pi[1:]
                     if pi:
-                        root = root[:-len(pi)]
+                        root = root[:root.rfind(root, pi)]
                     if req.env.has_key('REPO_NAME'):
                         rn = req.env['REPO_NAME'] + '/'
                         root += rn