[arch-commits] Commit in apache-ant/trunk (ant_diagnostics.patch)

Paul Mattal paul at archlinux.org
Sat Jun 5 21:06:46 UTC 2010


    Date: Saturday, June 5, 2010 @ 17:06:46
  Author: paul
Revision: 81848

added missing ant_diagnostics.patch

Added:
  apache-ant/trunk/ant_diagnostics.patch

-----------------------+
 ant_diagnostics.patch |   23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

Added: ant_diagnostics.patch
===================================================================
--- ant_diagnostics.patch	                        (rev 0)
+++ ant_diagnostics.patch	2010-06-05 21:06:46 UTC (rev 81848)
@@ -0,0 +1,23 @@
+--- a/src/main/org/apache/tools/ant/Diagnostics.java
++++ b/src/main/org/apache/tools/ant/Diagnostics.java
+@@ -179,7 +179,10 @@
+      * @param clazz the class to get the information from.
+      * @since Ant 1.8.0
+      */
+-    private static URL getClassLocation(Class clazz) {
++    private static URL getClassLocation(Class clazz) {
++		if (clazz.getProtectionDomain().getCodeSource() == null) {
++			return null;
++		}
+         return clazz.getProtectionDomain().getCodeSource().getLocation();
+     }
+ 
+@@ -241,7 +244,7 @@
+         }
+         Transformer transformer = null;
+         try {
+-            transformer = transformerFactory.newTransformer();
++            transformer = transformerFactory.newTransformer();
+         } catch (Exception e) {
+             // ignore
+             ignoreThrowable(e);




More information about the arch-commits mailing list