Mailing-List: contact cygwin-help@sourceware.cygnus.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@sources.redhat.com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin@sources.redhat.com>
List-Help: <mailto:cygwin-help@sources.redhat.com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner@sources.redhat.com
Delivered-To: mailing list cygwin@sources.redhat.com
Date: Sun, 18 Nov 2001 13:00:48 +0100
From: Corinna Vinschen <cygwin@cygwin.com>
To: cygwin@cygwin.com
Subject: Re: directory opening/closing behavior
Message-ID: <20011118130048.F31193@cygbert.vinschen.de>
Mail-Followup-To: cygwin@cygwin.com
References: <1006081063029880@firemail.de>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
User-Agent: Mutt/1.2.5i
In-Reply-To: <1006081063029880@firemail.de>; from oconnor@firemail.de on Sun, Nov 18, 2001 at 02:58:49AM -0800

On Sun, Nov 18, 2001 at 02:58:49AM -0800, Katherina O'Connor wrote:
> > Exactly what you've described. It's a 
> > Windows feature which isn't POSIX compatible 
> > and for which a workaround would be
> > extremly difficult.
> 
> Sorry, this isn't a "Windows feature" but 
> POSIX compatible and a workaround would be 
> extremly simple, because Chad Fowler made
> a simple mistake: he forgotten to call 
> closedir() before rmdir():

No, no.  What I meant is, in POSIX systems you can unlink() stuff
which is currently opened by the same or another process.  In
Windows you get a permission denied or something.  Cygwin has
actually a workaround which is to maintain a queue of stuff which
should be unlinked but couldn't due to open descriptors.  Therefore
the removing returns success since the unlink hasn't been done yet
but it's queued and will be performed when possible.  The following
mkdir fails since the directory still exists.  That's rather
difficult to do as a POSIX system expects with the underlying
Windows behaviour.

Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Developer                                mailto:cygwin@cygwin.com
Red Hat, Inc.

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

