Mailing-List: contact cygwin-developers-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-developers-owner AT cygwin DOT com Delivered-To: mailing list cygwin-developers AT cygwin DOT com Date: Wed, 22 May 2002 10:02:22 -0400 From: Jason Tishler Subject: Re: path_conv::check() gets confused by recently opened files In-reply-to: <20020522145627.G10218@cygbert.vinschen.de> To: Cygwin-Developers Mail-followup-to: Cygwin-Developers Message-id: <20020522140221.GH2124@tishler.net> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 7BIT Content-disposition: inline User-Agent: Mutt/1.3.24i References: <20020521200309 DOT GA2392 AT tishler DOT net> <20020522145627 DOT G10218 AT cygbert DOT vinschen DOT de> Corinna, On Wed, May 22, 2002 at 02:56:27PM +0200, Corinna Vinschen wrote: > On Tue, May 21, 2002 at 04:03:09PM -0400, Jason Tishler wrote: > > Unfortunately, I haven't figured out how to teach path_conv::check() > > to deal with recently opened files. I'm also a little leery to perturb > > this code. Any hints or help would be greatly appreciated. > > I found that path_conv::check() pinches off the tail when searching > for existing path components. I meant to mention the above in my post -- sorry, I was in a rush. > This strips the filename here from path_copy since it doesn't > exist yet. Actually, the file already "exists" -- at least it was open()-ed. > The effect is that > path_conv->normalized_path can't be correct when path_conv points > to a yet non-existant file. I don't see an easy way to get the > correct normalized path without introducing an additioanl temporary > copy of the path. Does it make any sense to do a reverse lookup (i.e., via name and/or hash) into cygheap->fdtab.fds[] to determine whether or not the file has been opened? Thanks, Jason