Commit 75fce135 authored by Stephane Bortzmeyer's avatar Stephane Bortzmeyer
Browse files

Catch "network unreachable" and other network errors

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