diff options
author | Senthil Kumaran <orsenthil@gmail.com> | 2010-12-29 06:29:58 (GMT) |
---|---|---|
committer | Senthil Kumaran <orsenthil@gmail.com> | 2010-12-29 06:29:58 (GMT) |
commit | e5f8e849c8b11acc7890425fcba051647d7bb35d (patch) | |
tree | 2fca750acf9de6f22a3f27dfb9c75b38bbe213a3 /Lib | |
parent | bb53bb40e6bac0b45ea20659f713117cd85c009f (diff) | |
download | cpython-e5f8e849c8b11acc7890425fcba051647d7bb35d.zip cpython-e5f8e849c8b11acc7890425fcba051647d7bb35d.tar.gz cpython-e5f8e849c8b11acc7890425fcba051647d7bb35d.tar.bz2 |
Merged revisions 87564 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r87564 | senthil.kumaran | 2010-12-29 14:25:42 +0800 (Wed, 29 Dec 2010) | 3 lines
Fix Issue 10753 - Don't quote ;=, in the PATH_INFO envvar.
........
Diffstat (limited to 'Lib')
-rwxr-xr-x | Lib/test/test_wsgiref.py | 4 | ||||
-rw-r--r-- | Lib/wsgiref/util.py | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/Lib/test/test_wsgiref.py b/Lib/test/test_wsgiref.py index 0b1a637..ef38d77 100755 --- a/Lib/test/test_wsgiref.py +++ b/Lib/test/test_wsgiref.py @@ -342,6 +342,10 @@ class UtilityTests(TestCase): self.checkReqURI("http://127.0.0.1/sp%C3%A4m", SCRIPT_NAME="/späm") self.checkReqURI("http://127.0.0.1/spammity/spam", SCRIPT_NAME="/spammity", PATH_INFO="/spam") + self.checkReqURI("http://127.0.0.1/spammity/spam;ham", + SCRIPT_NAME="/spammity", PATH_INFO="/spam;ham") + self.checkReqURI("http://127.0.0.1/spammity/spam;cookie=1234,5678", + SCRIPT_NAME="/spammity", PATH_INFO="/spam;cookie=1234,5678") self.checkReqURI("http://127.0.0.1/spammity/spam?say=ni", SCRIPT_NAME="/spammity", PATH_INFO="/spam",QUERY_STRING="say=ni") self.checkReqURI("http://127.0.0.1/spammity/spam", 0, diff --git a/Lib/wsgiref/util.py b/Lib/wsgiref/util.py index 00d1f26..06eb956 100644 --- a/Lib/wsgiref/util.py +++ b/Lib/wsgiref/util.py @@ -71,7 +71,7 @@ def request_uri(environ, include_query=True): """Return the full request URI, optionally including the query string""" url = application_uri(environ) from urllib.parse import quote - path_info = quote(environ.get('PATH_INFO','')) + path_info = quote(environ.get('PATH_INFO',''),safe='/;=,') if not environ.get('SCRIPT_NAME'): url += path_info[1:] else: |