Don't simply swallow all http server exceptions
This commit is contained in:
parent
d37fbb6c1a
commit
e6171127dc
1 changed files with 7 additions and 10 deletions
|
@ -82,7 +82,6 @@ class MyHandler(BaseHTTPRequestHandler):
|
|||
|
||||
def response(self, body, headers=None, code=200):
|
||||
headers = {} if headers is None else headers
|
||||
try:
|
||||
self.send_response(code)
|
||||
for key in headers:
|
||||
self.send_header(key, headers[key])
|
||||
|
@ -90,8 +89,6 @@ class MyHandler(BaseHTTPRequestHandler):
|
|||
self.end_headers()
|
||||
if body:
|
||||
self.wfile.write(body.encode('utf-8'))
|
||||
except Exception as exc:
|
||||
LOG.debug('Exception encountered while responding: %s', exc)
|
||||
|
||||
def answer_request(self, send_data):
|
||||
self.serverlist = self.server.client.getServerList()
|
||||
|
|
Loading…
Reference in a new issue