changeset 9 | 2a47b00f60b0 |
parent 8 | 0ce1f471e9d7 |
child 10 | d83b10c210e3 |
--- a/lib/http.py Fri Feb 06 22:48:00 2009 +0200 +++ b/lib/http.py Fri Feb 06 23:21:24 2009 +0200 @@ -51,7 +51,15 @@ /foo.cgi/quux/ -> quux/ """ - return os.path.normpath(self.env['PATH_INFO']).lstrip('/') + # the raw PATH_INFO + path_info = self.env.get('PATH_INFO') + + # avoid nasty '.' paths + if path_info : + return os.path.normpath(path_info).lstrip('/') + + else : + return '' class Response (object) : """