summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorJulien Cristau <jcristau@debian.org>2018-07-06 23:01:30 +0200
committerJulien Cristau <jcristau@debian.org>2018-07-06 23:01:57 +0200
commiteccb11406f0e2c901c21bac557c3f4720e20e20c (patch)
tree16582fd0f3ce772d3848bfb4e07dfa0911bcd8fb /lib
parent80d00dd36ba84e16e6fc578eb598d726a7f269ed (diff)
Also set Content-Length for HTMLResult
Diffstat (limited to 'lib')
-rw-r--r--lib/python/web_support.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/python/web_support.py b/lib/python/web_support.py
index da68b7d315..0f58d450ac 100644
--- a/lib/python/web_support.py
+++ b/lib/python/web_support.py
@@ -661,6 +661,7 @@ class HTMLResult(Result):
buf.write('\n')
self.contents.flatten(buf.write)
buf = buf.getvalue()
+ self.headers['Content-Length'] = str(len(buf))
def later(req):
headers_later(req)
req.wfile.write(buf)

© 2014-2024 Faster IT GmbH | imprint | privacy policy