diff --git a/app/src/main/java/eu/faircode/email/DnsHelper.java b/app/src/main/java/eu/faircode/email/DnsHelper.java index 686bdb30ff..b5f9744d07 100644 --- a/app/src/main/java/eu/faircode/email/DnsHelper.java +++ b/app/src/main/java/eu/faircode/email/DnsHelper.java @@ -47,7 +47,7 @@ import javax.mail.internet.InternetAddress; public class DnsHelper { // https://dns.watch/ private static final String DEFAULT_DNS = "84.200.69.80"; - private static final int DEFAULT_TIMEOUT = 15; // seconds + private static final int LOOKUP_TIMEOUT = 15; // seconds static void checkMx(Context context, Address[] addresses) throws UnknownHostException { if (addresses == null) @@ -67,7 +67,7 @@ public class DnsHelper { boolean found = true; try { SimpleResolver resolver = new SimpleResolver(getDnsServer(context)); - resolver.setTimeout(DEFAULT_TIMEOUT); + resolver.setTimeout(LOOKUP_TIMEOUT); Lookup lookup = new Lookup(domain, Type.MX); lookup.setResolver(resolver); lookup.run(); @@ -115,7 +115,7 @@ public class DnsHelper { try { SimpleResolver resolver = new SimpleResolver(getDnsServer(context)); - resolver.setTimeout(DEFAULT_TIMEOUT); + resolver.setTimeout(LOOKUP_TIMEOUT); Lookup lookup = new Lookup(name, rtype); lookup.setResolver(resolver); Log.i("Lookup name=" + name + " @" + resolver.getAddress() + " type=" + rtype);