diff options
author | Richard van der Hoff <github@rvanderhoff.org.uk> | 2017-11-27 12:19:18 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-11-27 12:19:18 +0000 |
commit | df6c72ede375ab10de7d6c090bcc555054e4d962 (patch) | |
tree | 041dcdff374d7462496e11690ed4ec34f1261cce /synapse/http/endpoint.py | |
parent | Merge pull request #2710 from matrix-org/rav/remove_dead_code (diff) | |
parent | Fix error handling on dns lookup (diff) | |
download | synapse-df6c72ede375ab10de7d6c090bcc555054e4d962.tar.xz |
Merge pull request #2711 from matrix-org/rav/fix_dns_errhandler
Fix error handling on dns lookup
Diffstat (limited to 'synapse/http/endpoint.py')
-rw-r--r-- | synapse/http/endpoint.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/synapse/http/endpoint.py b/synapse/http/endpoint.py index a97532162f..e2b99ef3bd 100644 --- a/synapse/http/endpoint.py +++ b/synapse/http/endpoint.py @@ -362,8 +362,10 @@ def _get_hosts_for_srv_record(dns_client, host): return res # no logcontexts here, so we can safely fire these off and gatherResults - d1 = dns_client.lookupAddress(host).addCallbacks(cb, eb) - d2 = dns_client.lookupIPV6Address(host).addCallbacks(cb, eb) + d1 = dns_client.lookupAddress(host).addCallbacks( + cb, eb, errbackArgs=("A", )) + d2 = dns_client.lookupIPV6Address(host).addCallbacks( + cb, eb, errbackArgs=("AAAA", )) results = yield defer.DeferredList( [d1, d2], consumeErrors=True) |