changeset 620:7369ec5d93f2

Attempt to handle RSS URIs properly -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Attempt to handle RSS URIs properly manifest hash: 1546939c11a8640ca56f0b0f5c7bdc878b4faa67 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.0 (GNU/Linux) iD8DBQFCycliywK+sNU5EO8RAukgAJ9eoJdqTiTQ8xSsSeHMIBmHnnQk9QCfQpFL SAJKUYknvv4IJDUyHjQc61k= =zGdJ -----END PGP SIGNATURE-----
author Matt Mackall <mpm@selenic.com>
date Mon, 04 Jul 2005 15:42:26 -0800
parents d96c1153b25d
children 004e811f7706
files mercurial/hgweb.py
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/hgweb.py	Mon Jul 04 12:54:42 2005 -0800
+++ b/mercurial/hgweb.py	Mon Jul 04 15:42:26 2005 -0800
@@ -610,8 +610,9 @@
 
         port = os.environ["SERVER_PORT"]
         port = port != "80" and (":" + port) or ""
-        url = "http://%s%s%s" % \
-              (os.environ["SERVER_NAME"], port, os.environ["REQUEST_URI"])
+        uri = os.environ["REQUEST_URI"]
+        if "?" in uri: uri = uri.split("?")[0]
+        url = "http://%s%s%s" % (os.environ["SERVER_NAME"], port, uri)
 
         self.t = templater(m, self.filters,
                            {"url":url,