You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by bo...@apache.org on 2009/10/24 07:28:12 UTC

svn commit: r829307 - /ant/core/trunk/src/main/org/apache/tools/ant/util/depend/bcel/FullAnalyzer.java

Author: bodewig
Date: Sat Oct 24 05:28:12 2009
New Revision: 829307

URL: http://svn.apache.org/viewvc?rev=829307&view=rev
Log:
Same fix as for AncestorAnalyzer - make code compile with BCEL's trunk

Modified:
    ant/core/trunk/src/main/org/apache/tools/ant/util/depend/bcel/FullAnalyzer.java

Modified: ant/core/trunk/src/main/org/apache/tools/ant/util/depend/bcel/FullAnalyzer.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/util/depend/bcel/FullAnalyzer.java?rev=829307&r1=829306&r2=829307&view=diff
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/util/depend/bcel/FullAnalyzer.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/util/depend/bcel/FullAnalyzer.java Sat Oct 24 05:28:12 2009
@@ -24,6 +24,7 @@
 import org.apache.bcel.classfile.ClassParser;
 import org.apache.bcel.classfile.DescendingVisitor;
 import org.apache.bcel.classfile.JavaClass;
+import org.apache.tools.ant.BuildException;
 import org.apache.tools.ant.util.depend.AbstractAnalyzer;
 
 /**
@@ -41,8 +42,13 @@
         // force BCEL classes to load now
         try {
             new ClassParser("force");
-        } catch (IOException e) {
-            // ignore
+        } catch (Exception e) {
+            // all released versions of BCEL may throw an IOException
+            // here, but BCEL's trunk does no longer declare to do so
+            if (!(e instanceof IOException)) {
+                throw new BuildException(e);
+            }
+            // ignore IOException like we've always done
         }
     }