ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Yuji Yamano <yyam...@kt.rim.or.jp>
Subject Patch for [Bug 25674]
Date Thu, 25 Dec 2003 09:17:20 GMT
> http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25674
> 
> delete with followSymlinks=false fails if pointed at non-existant directory

I think this patch will fix your problem. Could you try this?

Index: Delete.java
===================================================================
RCS file: /home/cvspublic/ant/src/main/org/apache/tools/ant/taskdefs/Delete.java,v
retrieving revision 1.47
diff -u -u -r1.47 Delete.java
--- Delete.java	13 Sep 2003 16:35:52 -0000	1.47
+++ Delete.java	25 Dec 2003 09:02:09 -0000
@@ -550,7 +550,8 @@
         }
 
         // delete the files from the default fileset
-        if (usedMatchingTask && dir != null) {
+        if (dir != null && dir.exists() && dir.isDirectory()
+            && usedMatchingTask) {
             try {
                 DirectoryScanner ds = super.getDirectoryScanner(dir);
                 String[] files = ds.getIncludedFiles();

-- 
Yuji Yamano <yyamano@kt.rim.or.jp>
  The music spread everywhere. In the mouth. In the armpits. In the crotch.
  The music a way of flying up and flying past. --Susan Sontag

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message