Author: mbenson
Date: Mon Jan 9 07:11:36 2006
New Revision: 367316
URL: http://svn.apache.org/viewcvs?rev=367316&view=rev
Log:
support failonerror when file locked or similar issue. Bugzilla report 38175.
Submitted by Georges-Etienne Legendre.
Modified:
ant/core/trunk/CONTRIBUTORS
ant/core/trunk/WHATSNEW
ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/Copy.java
Modified: ant/core/trunk/CONTRIBUTORS
URL:
http://svn.apache.org/viewcvs/ant/core/trunk/CONTRIBUTORS?rev=367316&r1=367315&r2=367316&view=diff
==============================================================================
--- ant/core/trunk/CONTRIBUTORS (original)
+++ ant/core/trunk/CONTRIBUTORS Mon Jan 9 07:11:36 2006
@@ -72,6 +72,7 @@
Frederic Lavigne
Gary S. Weaver
Gautam Guliani
+Georges-Etienne Legendre
Gero Vermaas
Gerrit Riessen
Glenn McAllister
Modified: ant/core/trunk/WHATSNEW
URL:
http://svn.apache.org/viewcvs/ant/core/trunk/WHATSNEW?rev=367316&r1=367315&r2=367316&view=diff
==============================================================================
--- ant/core/trunk/WHATSNEW (original)
+++ ant/core/trunk/WHATSNEW Mon Jan 9 07:11:36 2006
@@ -175,6 +175,9 @@
* Project not set on ChainReaderHelpers used by the Redirector.
Bugzilla report 37958.
+* Copy task would fail on locked (or otherwise uncopyable) files even if
+ failonerror set to false. Bugzilla report 38175.
+
Other changes:
--------------
* Minor performance improvements Bugzilla report 37777
Modified: ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/Copy.java
URL:
http://svn.apache.org/viewcvs/ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/Copy.java?rev=367316&r1=367315&r2=367316&view=diff
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/Copy.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/taskdefs/Copy.java Mon Jan 9
07:11:36 2006
@@ -799,7 +799,10 @@
if (targetFile.exists() && !targetFile.delete()) {
msg += " and I couldn't delete the corrupt " +
toFile;
}
- throw new BuildException(msg, ioe, getLocation());
+ if (failonerror) {
+ throw new BuildException(msg, ioe, getLocation());
+ }
+ log(msg, Project.MSG_ERR);
}
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]