If directory is specified test if it's a valid one.
Index: ExecTask.java
===================================================================
RCS file:
/home/cvspublic/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/ExecTask.java,v
retrieving revision 1.11
diff -u -r1.11 ExecTask.java
--- ExecTask.java 2001/01/03 14:18:29 1.11
+++ ExecTask.java 2001/01/20 22:15:40
@@ -170,6 +170,12 @@
if (cmdl.getExecutable() == null) {
throw new BuildException("no executable specified", location);
}
+ if (dir != null && !dir.exists()) {
+ throw new BuildException("The directory you specified does not
exist");
+ }
+ if (dir != null && !dir.isDirectory()) {
+ throw new BuildException("The directory you specified is not a
directory");
+ }
}
/**