Commit cc16c0ed authored by Denis Bilenko's avatar Denis Bilenko

fix an AttributeError that happens when a request that is failed is logged

parent 2b18cd90
...@@ -246,6 +246,7 @@ class HttpProtocol(BaseHTTPServer.BaseHTTPRequestHandler): ...@@ -246,6 +246,7 @@ class HttpProtocol(BaseHTTPServer.BaseHTTPRequestHandler):
if not self.headers_sent or self.response_use_chunked: if not self.headers_sent or self.response_use_chunked:
self.write('') self.write('')
except Exception: except Exception:
self.status = '500 Internal Server Error'
self.close_connection = 1 self.close_connection = 1
exc = traceback.format_exc() exc = traceback.format_exc()
print exc print exc
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment