From 19c1484053c49f31d5d858e1ed3fcbd2f33cb5ad Mon Sep 17 00:00:00 2001 From: Daniel Gultsch Date: Tue, 11 Jul 2017 23:24:09 +0200 Subject: [PATCH] catch runtime exceptions from minidns --- src/main/java/eu/siacs/conversations/utils/Resolver.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/eu/siacs/conversations/utils/Resolver.java b/src/main/java/eu/siacs/conversations/utils/Resolver.java index 9716fa882..c8c20e7e5 100644 --- a/src/main/java/eu/siacs/conversations/utils/Resolver.java +++ b/src/main/java/eu/siacs/conversations/utils/Resolver.java @@ -48,13 +48,13 @@ public class Resolver { List results = new ArrayList<>(); try { results.addAll(resolveSrv(domain,true)); - } catch (IOException e) { - Log.d(Config.LOGTAG,Resolver.class.getSimpleName()+": "+e.getMessage()); + } catch (Throwable throwable) { + Log.d(Config.LOGTAG,Resolver.class.getSimpleName()+": error resolving SRV record (direct TLS)",throwable); } try { results.addAll(resolveSrv(domain,false)); - } catch (IOException e) { - Log.d(Config.LOGTAG,Resolver.class.getSimpleName()+": "+e.getMessage()); + } catch (Throwable throwable) { + Log.d(Config.LOGTAG,Resolver.class.getSimpleName()+": error resolving SRV record (STARTTLS)",throwable); } if (results.size() == 0) { results.addAll(resolveNoSrvRecords(DNSName.from(domain),true));