Summary: | replace task failed to delete file | ||
---|---|---|---|
Product: | Ant | Reporter: | Support niveau 3 Agora <support_niveau_3_socle_technique_j2ee.grprec> |
Component: | Core tasks | Assignee: | Ant Notifications List <notifications> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | notifications |
Priority: | P2 | ||
Version: | 1.7.1 | ||
Target Milestone: | 1.8.0 | ||
Hardware: | PC | ||
OS: | Windows XP |
Description
Support niveau 3 Agora
2008-10-07 00:22:20 UTC
I've looked through my archives of the last two years but don't find the post you talked about, it may have been older than that. Anyway. Ant has just closed the file (because it had to read it) and it may very well be that the JVM hasn't released the file handle to the operating system yet (and your call to GC made it release the handle). We have had similar cases in <delete> where we explicitly insert a System.gc() on Windows and retry after sleeping for a 10 millis if a call to delete() fails - we could introduce the same in replace as well. should work better with svn trunk revision 703151. I'll test as soon as possible. Thanks correction seems good but I can't access to Apache SVN repositories from my company. you can download a snapshot of Ant's trunk from http://svn.apache.org/snapshots/ant/ I've just made a test. The bug is fixed. |