Commit cbab2458 authored by Guus der Kinderen's avatar Guus der Kinderen

Log a stacktrace when something erroneous occurs.

parent 18069a03
...@@ -334,15 +334,7 @@ public class LocalOutgoingServerSession extends LocalServerSession implements Ou ...@@ -334,15 +334,7 @@ public class LocalOutgoingServerSession extends LocalServerSession implements Ou
catch (SSLHandshakeException e) { catch (SSLHandshakeException e) {
Log.debug("LocalOutgoingServerSession: Handshake error while creating secured outgoing session to remote " + Log.debug("LocalOutgoingServerSession: Handshake error while creating secured outgoing session to remote " +
"server: " + hostname + "(DNS lookup: " + realHostname + ":" + realPort + "server: " + hostname + "(DNS lookup: " + realHostname + ":" + realPort +
"):" + e.toString()); "):", e);
// Close the connection
if (connection != null) {
connection.close();
}
}
catch (XmlPullParserException e) {
Log.warn("Error creating secured outgoing session to remote server: " + hostname +
"(DNS lookup: " + realHostname + ":" + realPort + "): " + e.toString());
// Close the connection // Close the connection
if (connection != null) { if (connection != null) {
connection.close(); connection.close();
...@@ -350,7 +342,7 @@ public class LocalOutgoingServerSession extends LocalServerSession implements Ou ...@@ -350,7 +342,7 @@ public class LocalOutgoingServerSession extends LocalServerSession implements Ou
} }
catch (Exception e) { catch (Exception e) {
Log.error("Error creating secured outgoing session to remote server: " + hostname + Log.error("Error creating secured outgoing session to remote server: " + hostname +
"(DNS lookup: " + realHostname + ":" + realPort + "): " + e.toString()); "(DNS lookup: " + realHostname + ":" + realPort + ")", e);
// Close the connection // Close the connection
if (connection != null) { if (connection != null) {
connection.close(); connection.close();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment