Commit 4584615b authored by Denis Bilenko's avatar Denis Bilenko

fix invalid error code in an exception handler. Patch by Uriel Katz.

parent cc16c0ed
......@@ -170,7 +170,7 @@ class HttpProtocol(BaseHTTPServer.BaseHTTPRequestHandler):
self.handle_one_response()
except socket.error, e:
# Broken pipe, connection reset by peer
if e[0] in (32, 54):
if e[0] in (errno.EPIPE, errno.ECONNRESET):
pass
else:
raise
......
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