geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jsis...@apache.org
Subject svn commit: r407995 - /geronimo/branches/1.1/applications/console-standard/src/java/org/apache/geronimo/console/jmsmanager/wizard/JMSProviderData.java
Date Sat, 20 May 2006 13:18:55 GMT
Author: jsisson
Date: Sat May 20 06:18:54 2006
New Revision: 407995

URL: http://svn.apache.org/viewvc?rev=407995&view=rev
Log:
GERONIMO-2032 - [console] ensure input streams is closed in a finally block

Modified:
    geronimo/branches/1.1/applications/console-standard/src/java/org/apache/geronimo/console/jmsmanager/wizard/JMSProviderData.java

Modified: geronimo/branches/1.1/applications/console-standard/src/java/org/apache/geronimo/console/jmsmanager/wizard/JMSProviderData.java
URL: http://svn.apache.org/viewvc/geronimo/branches/1.1/applications/console-standard/src/java/org/apache/geronimo/console/jmsmanager/wizard/JMSProviderData.java?rev=407995&r1=407994&r2=407995&view=diff
==============================================================================
--- geronimo/branches/1.1/applications/console-standard/src/java/org/apache/geronimo/console/jmsmanager/wizard/JMSProviderData.java
(original)
+++ geronimo/branches/1.1/applications/console-standard/src/java/org/apache/geronimo/console/jmsmanager/wizard/JMSProviderData.java
Sat May 20 06:18:54 2006
@@ -220,6 +220,7 @@
                     DocumentBuilder builder = factory.newDocumentBuilder();
                     doc = builder.parse(in);
                     in.close();
+                    in = null;
                     break;
                 } else in.closeEntry();
             }
@@ -227,6 +228,12 @@
             log.error("Unable to read META-INF/ra.xml in RAR file '"+data.getRaURI()+"'",
e);
         } catch (SAXException e) {
             log.error("Unable to read META-INF/ra.xml in RAR file '"+data.getRaURI()+"'",
e);
+        } finally {
+            if (in != null)
+                try {
+                    in.close();        
+                } catch (IOException ignore) {
+                }
         }
         if(doc == null) {
             throw new IOException("Unable to locate META-INF/ra.xml in RAR file '"+data.getRaURI()+"'");



Mime
View raw message