chiark / gitweb /
wip
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 23 Mar 2017 19:45:41 +0000 (19:45 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 23 Mar 2017 19:45:41 +0000 (19:45 +0000)
server

diff --git a/server b/server
index 17dcd5d..1b43fb0 100755 (executable)
--- a/server
+++ b/server
@@ -139,9 +139,8 @@ class IphttpResource(twisted.web.resource.Resource):
     except Exception as e:
       request.setHeader('Content-Type','text/plain; charset="utf-8"')
       request.setResponseCode(400)
-      request.write(str(e).encode('utf-8'))
-      request.finish
-      
+      return str(e).encode('utf-8')
+
   def render_GET(self, request):
     return b'<html><body>hippotat</body></html>'