From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19251 invoked by alias); 15 Jun 2008 03:27:17 -0000 Received: (qmail 19241 invoked by uid 22791); 15 Jun 2008 03:27:16 -0000 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sun, 15 Jun 2008 03:26:57 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id 2329598408; Sun, 15 Jun 2008 03:26:55 +0000 (GMT) Received: from caradoc.them.org (22.svnf5.xdsl.nauticom.net [209.195.183.55]) by nan.false.org (Postfix) with ESMTP id D943098402; Sun, 15 Jun 2008 03:26:54 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.69) (envelope-from ) id 1K7itK-0001Ol-15; Sat, 14 Jun 2008 23:26:54 -0400 Date: Sun, 15 Jun 2008 17:43:00 -0000 From: Daniel Jacobowitz To: Eli Zaretskii Cc: Vladimir Prus , gdb-patches@sources.redhat.com Subject: Re: Better realpath Message-ID: <20080615032653.GA5214@caradoc.them.org> Mail-Followup-To: Eli Zaretskii , Vladimir Prus , gdb-patches@sources.redhat.com References: <200806141024.41812.vladimir@codesourcery.com> <200806141614.07742.vladimir@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2008-05-11) X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2008-06/txt/msg00275.txt.bz2 On Sun, Jun 15, 2008 at 06:18:45AM +0300, Eli Zaretskii wrote: > > > Alternatively, we could refrain from > > > using realpath, in which case we should consistently _not_ require > > > that the file exists. > > > > ... as I've said, I can modify gdb_realpath to check for file existance, > > on Windows, which will make the behaviour of gdb_realpath the same > > everywhere. > > The question is, what kind of consistent behavior do we want. > Personally, I think realpath's behavior is wrong for most GDB usages, > that's why I suggested the alternative. It seems to me that the thing to do is eliminate gdb_realpath in favor of lrealpath. That's supposed to be a portable version of realpath, so realpath semantics seem like the way to go. Why do you think realpath's behavior is wrong for GDB? The only times we're interested in realpath should be when we have an actual on-disk file. If it doesn't exist, its expanded path is not important. -- Daniel Jacobowitz CodeSourcery