Show More
@@ -127,6 +127,11 b' class _hgwebhandler(object, BaseHTTPServ' | |||
|
127 | 127 | if h[0].lower() == 'content-length': |
|
128 | 128 | should_close = False |
|
129 | 129 | self.length = int(h[1]) |
|
130 | # The value of the Connection header is a list of case-insensitive | |
|
131 | # tokens separated by commas and optional whitespace. | |
|
132 | if 'close' in [token.strip().lower() for token in | |
|
133 | self.headers.get('connection', '').split(',')]: | |
|
134 | should_close = True | |
|
130 | 135 | if should_close: |
|
131 | 136 | self.send_header('Connection', 'close') |
|
132 | 137 | self.close_connection = should_close |
General Comments 0
You need to be logged in to leave comments.
Login now