Don't show strack trace on stdout but instead log it

This commit is contained in:
Laurent Clouet
2017-04-19 21:23:12 +02:00
parent 8b92cba01e
commit 6a2cc2b8a6
2 changed files with 74 additions and 27 deletions

View File

@@ -492,8 +492,11 @@ public class Client {
this.server.HTTPSendFile(this.server.getPage("error") + args, temp_file.getAbsolutePath());
temp_file.delete();
}
catch (Exception e1) {
e1.printStackTrace();
catch (Exception e) {
StringWriter sw = new StringWriter();
PrintWriter pw = new PrintWriter(sw);
e.printStackTrace(pw);
this.log.debug("Client::sendError Exception " + e + " stacktrace: " + sw.toString());
// no exception should be raised to actual launcher (applet or standalone)
}