tomee-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jlaskow...@apache.org
Subject svn commit: r596300 - /openejb/trunk/openejb3/server/openejb-client/src/main/java/org/apache/openejb/client/Client.java
Date Mon, 19 Nov 2007 13:54:30 GMT
Author: jlaskowski
Date: Mon Nov 19 05:54:29 2007
New Revision: 596300

URL: http://svn.apache.org/viewvc?rev=596300&view=rev
Log:
Avoid printing out a message "Error closing connection with server: null" when no openejb
is running

Modified:
    openejb/trunk/openejb3/server/openejb-client/src/main/java/org/apache/openejb/client/Client.java

Modified: openejb/trunk/openejb3/server/openejb-client/src/main/java/org/apache/openejb/client/Client.java
URL: http://svn.apache.org/viewvc/openejb/trunk/openejb3/server/openejb-client/src/main/java/org/apache/openejb/client/Client.java?rev=596300&r1=596299&r2=596300&view=diff
==============================================================================
--- openejb/trunk/openejb3/server/openejb-client/src/main/java/org/apache/openejb/client/Client.java
(original)
+++ openejb/trunk/openejb3/server/openejb-client/src/main/java/org/apache/openejb/client/Client.java
Mon Nov 19 05:54:29 2007
@@ -207,10 +207,11 @@
 
         } finally {
             try {
-                conn.close();
+            	if (conn != null) {
+            	    conn.close();
+            	}
             } catch (Throwable t) {
-
-                System.out.println("Error closing connection with server: " + t.getMessage());
+                logger.log(Level.WARNING, "Error closing connection with server: " + t.getMessage(),
t);
             }
         }
         return res;



Mime
View raw message