Return-Path: Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 30735 invoked by uid 500); 15 Jul 2003 18:08:51 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 30723 invoked from network); 15 Jul 2003 18:08:50 -0000 Received: from mr-mcfeeley.fgm.com (216.1.16.101) by daedalus.apache.org with SMTP; 15 Jul 2003 18:08:50 -0000 Received: from [207.158.2.130] (sd.fgm.com [207.158.2.130]) by mr-mcfeeley.fgm.com (8.11.6/8.11.2) with ESMTP id h6FI31m07937 for ; Tue, 15 Jul 2003 14:03:01 -0400 Message-ID: <3F144334.80606@alumni.pitt.edu> Date: Tue, 15 Jul 2003 11:08:52 -0700 From: __matthewHawthorne User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.4) Gecko/20030624 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Ant Users List Subject: Re: Unable to delete directory References: <3F14166C.8010708@fgm.com> <3F143EBC.5060201@fgm.com> In-Reply-To: <3F143EBC.5060201@fgm.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Another option is a flag which configures if non-delete-able files cause an error. In Ant's code, if File.delete() returns false, you can call File.deleteOnExit(), which will do it's best to delete the file during JVM shutdown. I've had some luck deleting mysterious files using this technique, and not so much luck while attempting to sleep and then delete again. Daniel Barclay wrote: > Stefan Bodewig wrote: > >> On Tue, 15 Jul 2003, Daniel Barclay wrote: >> >>> Does it just sleep and then proceed, or does it also wait for >>> successful deletion? >> >> >> Neither nor. It tries to delete, sleeps if it fails and tries to >> delete again. If that second attempt fails, will fail. >> >> There may be a lot of legitimate reasons why you cannot delete the >> file, trying until you succeed may never return. > > > Can Ant detect when it has requested the deletion of a file within > the directory and the file hasn't actually been deleted yet (if that's > even the case you all are talking about)? > > Daniel > > > > > > > > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: user-unsubscribe@ant.apache.org > For additional commands, e-mail: user-help@ant.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org