mbenson 2005/02/07 15:25:03
Modified: src/main/org/apache/tools/ant/taskdefs ExecuteJava.java
Log:
Remove temp variable/method call, some blank lines
Revision Changes Path
1.46 +1 -8
ant/src/main/org/apache/tools/ant/taskdefs/ExecuteJava.java
Index: ExecuteJava.java
===================================================================
RCS file:
/home/cvs/ant/src/main/org/apache/tools/ant/taskdefs/ExecuteJava.java,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -r1.45 -r1.46
--- ExecuteJava.java 2 Feb 2005 12:52:47 -0000 1.45
+++ ExecuteJava.java 7 Feb 2005 23:25:03 -0000 1.46
@@ -103,8 +103,6 @@
if (sysProperties != null) {
sysProperties.setSystem();
}
-
- final Class[] param = {Class.forName("[Ljava.lang.String;")};
Class target = null;
if (classpath == null) {
target = Class.forName(classname);
@@ -118,18 +116,15 @@
loader.forceLoadClass(classname);
target = Class.forName(classname, true, loader);
}
- main = target.getMethod("main", param);
+ main = target.getMethod("main", new Class[] {String[].class});
if (main == null) {
throw new BuildException("Could not find main() method in "
+ classname);
}
-
if ((main.getModifiers() & Modifier.STATIC) == 0) {
throw new BuildException("main() method in " + classname
+ " is not declared static");
}
-
-
if (timeout == null) {
run();
} else {
@@ -161,11 +156,9 @@
}
}
}
-
if (caught != null) {
throw caught;
}
-
} catch (ClassNotFoundException e) {
throw new BuildException("Could not find " + classname + "."
+ " Make sure you have it in your"
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]