mercurial/hgweb/wsgicgi.py
changeset 4076 5a89c61c189c
parent 3673 eb0b4a2d70a9
child 4496 7605da1c3b5c
equal deleted inserted replaced
4075:31a679ae7eef 4076:5a89c61c189c
     7 #
     7 #
     8 # This was originally copied from the public domain code at
     8 # This was originally copied from the public domain code at
     9 # http://www.python.org/dev/peps/pep-0333/#the-server-gateway-side
     9 # http://www.python.org/dev/peps/pep-0333/#the-server-gateway-side
    10 
    10 
    11 import os, sys
    11 import os, sys
       
    12 from mercurial import util
    12 
    13 
    13 def launch(application):
    14 def launch(application):
       
    15     util.set_binary(sys.stdout)
    14 
    16 
    15     environ = dict(os.environ.items())
    17     environ = dict(os.environ.items())
    16     environ['wsgi.input'] = sys.stdin
    18     environ['wsgi.input'] = sys.stdin
    17     environ['wsgi.errors'] = sys.stderr
    19     environ['wsgi.errors'] = sys.stderr
    18     environ['wsgi.version'] = (1, 0)
    20     environ['wsgi.version'] = (1, 0)