From 16f500430176e9f7466088ac5f3a5aa16aa3e111 Mon Sep 17 00:00:00 2001 From: Matt Tucker Date: Mon, 15 Mar 2004 22:59:03 +0000 Subject: [PATCH] Write out error if failed to load custom debugger. git-svn-id: http://svn.igniterealtime.org/svn/repos/smack/trunk@2257 b35dd754-fafc-0310-a699-88a17e54d16e --- source/org/jivesoftware/smack/XMPPConnection.java | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/source/org/jivesoftware/smack/XMPPConnection.java b/source/org/jivesoftware/smack/XMPPConnection.java index 6e1828655..8539dda13 100644 --- a/source/org/jivesoftware/smack/XMPPConnection.java +++ b/source/org/jivesoftware/smack/XMPPConnection.java @@ -690,13 +690,18 @@ public class XMPPConnection { // Detect the debugger class to use. String className = System.getProperty("smack.debuggerClass"); Class debuggerClass = null; - try { - debuggerClass = Class.forName(className); + if (className != null) { + try { + debuggerClass = Class.forName(className); + } + catch (Exception e) { + e.printStackTrace(); + } } - catch (Exception e) { + if (debuggerClass == null) { try { debuggerClass = - Class.forName("org.jivesoftware.smackx.debugger.EnhancedDebugger"); + Class.forName("org.jivesoftware.smackx.debugger.EnhancedDebugger"); } catch (Exception ex) { debuggerClass = LiteDebugger.class;