From 315648382ec2b1fd59c36e388e0fae5d23b3b9a6 Mon Sep 17 00:00:00 2001 From: Florian Schmaus Date: Sun, 8 Jun 2014 13:54:51 +0200 Subject: [PATCH] Remove printStackTrace() calls it's hard to assign those an app in the Android log. Better to use JUL. --- src/main/java/de/measite/minidns/Client.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/de/measite/minidns/Client.java b/src/main/java/de/measite/minidns/Client.java index e20c007e..b5712d24 100644 --- a/src/main/java/de/measite/minidns/Client.java +++ b/src/main/java/de/measite/minidns/Client.java @@ -14,6 +14,7 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.HashSet; import java.util.Random; +import java.util.logging.Level; import java.util.logging.Logger; import de.measite.minidns.Record.CLASS; @@ -238,7 +239,7 @@ public class Client { return server.toArray(new String[server.size()]); } } catch (IOException e) { - e.printStackTrace(); + LOGGER.log(Level.WARNING, "Exception in findDNSByExec", e); } return null; } @@ -283,7 +284,7 @@ public class Client { } } catch (Exception e) { // we might trigger some problems this way - e.printStackTrace(); + LOGGER.log(Level.WARNING, "Exception in findDNSByReflection", e); } return null; }