ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin van Wieringen <>
Subject RE: W2000 SP1 Delete of directory fails
Date Sun, 10 Feb 2002 20:04:33 GMT

> From: Steve Holdener []
> Sent: Wednesday, February 06, 2002 5:48 PM
> To: Ant Users List
> Subject: Re: W2000 SP1 Delete of directory fails
> Martin van Wieringen wrote:
> > When I have a build.xml file which creates the build
> directory, compiles
> > the classes to the build directory then put the .class file
> on a jar file
> > in the dist directory and at the end deletes the entire
> build directory. It
> > works fine however if I envoke the build two times after
> each other then it
> > W2000 seems to lock the build directory so that the second
> build result in
> > failure when it tries to recreate the directory.
> I saw similar behavior on my W2000/SP2 box yesterday.  I
> closed all open
> apps, and it still wouldn't delete the directory ("Access
> Denied"), so I
> rebooted.

Yes, well rebooting is a bit drastic. I found that if you simple wait like 
an hour or so leaving the directory alone then all of a sudden you can d  
elete it.

> BTW, after Ant attempts to delete the directory, the dir
> appears stuck
> in some strange limbo state.  It will show up in the explorer, but I
> can't even select it without getting the error.  IIRC, I was
> not able to
> see it from a command prompt.

Sound exactly like the problem I am having.

> I've not been able to reproduce this
> today, but I'll let you know if I can get any more details.

Yes, well I can give you some more details. It is guarenteed to happen if 
you call ant quickly several times after eachother.
Also I suspect that ant is doing things to fast and that is why windows 
2000 locks the directory. Perhaps if we would have ant wait for 2 seconds 
before deleting the dir windows 2000 would not lock it.

Anyway which service Pack are you running with on windows 2000? Perhaps a 
new servicepack fixes this windows 2000 feature.

Does anybody got any idea how to prevent windows 2000 from locking 


Martin van Wieringen

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message