tdnssec: don't call get_default_resolver - electrum - Electrum Bitcoin wallet HTML git clone https://git.parazyd.org/electrum DIR Log DIR Files DIR Refs DIR Submodules --- DIR commit 963ec4ca3e511902f7b358ee001c281931b42306 DIR parent 9938fbd16026dae739b71acff144bf2191d6cf7e HTML Author: ThomasV <thomasv@gitorious> Date: Fri, 31 Jul 2015 20:02:55 +0200 dnssec: don't call get_default_resolver Diffstat: M lib/dnssec.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) --- DIR diff --git a/lib/dnssec.py b/lib/dnssec.py t@@ -243,16 +243,16 @@ def get_and_validate(ns, url, _type): def query(url, rtype): - resolver = dns.resolver.get_default_resolver() # 8.8.8.8 is Google's public DNS server - resolver.nameservers = ['8.8.8.8'] - ns = resolver.nameservers[0] + nameservers = ['8.8.8.8'] + ns = nameservers[0] try: out = get_and_validate(ns, url, rtype) validated = True except BaseException as e: #traceback.print_exc(file=sys.stderr) print_error("DNSSEC error:", str(e)) + resolver = dns.resolver.get_default_resolver() out = resolver.query(url, rtype) validated = False return out, validated