Commit dc59841f authored by Stephane Bortzmeyer's avatar Stephane Bortzmeyer
Browse files

Handles OSError

parent a5251758
...@@ -373,6 +373,10 @@ class ConnectionDoT(Connection): ...@@ -373,6 +373,10 @@ class ConnectionDoT(Connection):
if self.verbose: if self.verbose:
print("Timeout") print("Timeout")
return False return False
except OSError:
if self.verbose:
print("Cannot connect")
return False
# RFC 7858, section 4.2 and appendix A # RFC 7858, section 4.2 and appendix A
self.cert = self.session.get_peer_certificate() self.cert = self.session.get_peer_certificate()
self.publickey = self.cert.get_pubkey() self.publickey = self.cert.get_pubkey()
......
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