Author: jglick
Date: Fri Aug 8 08:23:17 2008
New Revision: 683997
URL: http://svn.apache.org/viewvc?rev=683997&view=rev
Log:
Better error reporting in case a corrupt ZIP file is on the classpath.
Formerly would show a ZipException stack trace but give no indication of which
file was responsible.
(Of course it would be better if ZipFile.open itself included the file path in
the detail message!)
Cf.: http://www.netbeans.org/nonav/issues/show_bug.cgi?id=142733
Modified:
ant/core/trunk/src/main/org/apache/tools/ant/AntClassLoader.java
Modified: ant/core/trunk/src/main/org/apache/tools/ant/AntClassLoader.java
URL:
http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/AntClassLoader.java?rev=683997&r1=683996&r2=683997&view=diff
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/AntClassLoader.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/AntClassLoader.java Fri Aug 8
08:23:17 2008
@@ -984,6 +984,7 @@
}
}
} catch (Exception e) {
+ log("Unable to obtain resource from " + file + ": " + e,
Project.MSG_WARN);
e.printStackTrace();
}
return null;