commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tcu...@apache.org
Subject svn commit: r1102604 - in /commons/proper/jci/trunk/compilers: eclipse/src/main/java/org/apache/commons/jci/compilers/EclipseJavaCompiler.java rhino/src/test/java/org/apache/commons/jci/compilers/RhinoJavaCompilerTestCase.java
Date Fri, 13 May 2011 08:29:29 GMT
Author: tcurdt
Date: Fri May 13 08:29:28 2011
New Revision: 1102604

URL: http://svn.apache.org/viewvc?rev=1102604&view=rev
Log:
skip NA tests,
fixed resource names,
don't leak input stream


Modified:
    commons/proper/jci/trunk/compilers/eclipse/src/main/java/org/apache/commons/jci/compilers/EclipseJavaCompiler.java
    commons/proper/jci/trunk/compilers/rhino/src/test/java/org/apache/commons/jci/compilers/RhinoJavaCompilerTestCase.java

Modified: commons/proper/jci/trunk/compilers/eclipse/src/main/java/org/apache/commons/jci/compilers/EclipseJavaCompiler.java
URL: http://svn.apache.org/viewvc/commons/proper/jci/trunk/compilers/eclipse/src/main/java/org/apache/commons/jci/compilers/EclipseJavaCompiler.java?rev=1102604&r1=1102603&r2=1102604&view=diff
==============================================================================
--- commons/proper/jci/trunk/compilers/eclipse/src/main/java/org/apache/commons/jci/compilers/EclipseJavaCompiler.java
(original)
+++ commons/proper/jci/trunk/compilers/eclipse/src/main/java/org/apache/commons/jci/compilers/EclipseJavaCompiler.java
Fri May 13 08:29:28 2011
@@ -236,7 +236,7 @@ public final class EclipseJavaCompiler e
 
                 final String resourceName = ConversionUtils.convertClassToResourcePath(pClazzName);
 
-                final byte[] clazzBytes = pStore.read(pClazzName);
+                final byte[] clazzBytes = pStore.read(resourceName);
                 if (clazzBytes != null) {
                     log.debug("loading from store " + pClazzName);
 
@@ -294,6 +294,11 @@ public final class EclipseJavaCompiler e
                 final InputStream is = pClassLoader.getResourceAsStream(ConversionUtils.convertClassToResourcePath(pClazzName));
                 if (is != null) {
                     log.debug("found the class for " + pClazzName + "- no package");
+                    try {
+                        is.close();
+                    } catch (final IOException ie) {
+                        log.error("could not close input stream", ie);
+                    } 
                     return false;
                 }
 

Modified: commons/proper/jci/trunk/compilers/rhino/src/test/java/org/apache/commons/jci/compilers/RhinoJavaCompilerTestCase.java
URL: http://svn.apache.org/viewvc/commons/proper/jci/trunk/compilers/rhino/src/test/java/org/apache/commons/jci/compilers/RhinoJavaCompilerTestCase.java?rev=1102604&r1=1102603&r2=1102604&view=diff
==============================================================================
--- commons/proper/jci/trunk/compilers/rhino/src/test/java/org/apache/commons/jci/compilers/RhinoJavaCompilerTestCase.java
(original)
+++ commons/proper/jci/trunk/compilers/rhino/src/test/java/org/apache/commons/jci/compilers/RhinoJavaCompilerTestCase.java
Fri May 13 08:29:28 2011
@@ -118,8 +118,11 @@ public final class RhinoJavaCompilerTest
     }
 
     public void testCrossReferenceCompilation() throws Exception {
-        
+        // NA
     }
 
+    public void testAdditionalTopLevelClassCompile() throws Exception {
+        // NA
+    }
 
 }



Mime
View raw message