Mercurial > hg
comparison mercurial/hgweb/wsgicgi.py @ 5579:e15f7db0f0ee
Use SCRIPT_NAME and PATH_INFO instead of REQUEST_URI. This is required by WSGI (fixes issue846).
author | Dirkjan Ochtman <dirkjan@ochtman.nl> |
---|---|
date | Sat, 01 Dec 2007 19:19:08 +0100 |
parents | e0173902c813 |
children | f429e0e067a8 |
comparison
equal
deleted
inserted
replaced
5578:733b50883f73 | 5579:e15f7db0f0ee |
---|---|
14 def launch(application): | 14 def launch(application): |
15 util.set_binary(sys.stdin) | 15 util.set_binary(sys.stdin) |
16 util.set_binary(sys.stdout) | 16 util.set_binary(sys.stdout) |
17 | 17 |
18 environ = dict(os.environ.items()) | 18 environ = dict(os.environ.items()) |
19 if 'PATH_INFO' not in environ: | |
20 environ['PATH_INFO'] = '' | |
21 | |
19 environ['wsgi.input'] = sys.stdin | 22 environ['wsgi.input'] = sys.stdin |
20 environ['wsgi.errors'] = sys.stderr | 23 environ['wsgi.errors'] = sys.stderr |
21 environ['wsgi.version'] = (1, 0) | 24 environ['wsgi.version'] = (1, 0) |
22 environ['wsgi.multithread'] = False | 25 environ['wsgi.multithread'] = False |
23 environ['wsgi.multiprocess'] = True | 26 environ['wsgi.multiprocess'] = True |