From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1084 invoked by alias); 4 May 2005 02:32:24 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 985 invoked from network); 4 May 2005 02:32:14 -0000 Received: from unknown (HELO lakermmtao01.cox.net) (68.230.240.38) by sourceware.org with SMTP; 4 May 2005 02:32:14 -0000 Received: from white ([68.9.64.121]) by lakermmtao01.cox.net (InterMail vM.6.01.04.00 201-2131-118-20041027) with ESMTP id <20050504023212.XFJJ11036.lakermmtao01.cox.net@white> for ; Tue, 3 May 2005 22:32:12 -0400 Received: from bob by white with local (Exim 3.35 #1 (Debian)) id 1DT9gK-0006th-00 for ; Tue, 03 May 2005 22:32:12 -0400 Date: Wed, 04 May 2005 02:32:00 -0000 From: Bob Rossi To: gdb-patches@sources.redhat.com Subject: Re: [RFC] fullname attribute for GDB/MI stack frames Message-ID: <20050504023212.GA26243@white> Mail-Followup-To: gdb-patches@sources.redhat.com References: <01c54f57$Blat.v2.4$4c163500@zahav.net.il> <20050502204859.GA6090@nevyn.them.org> <01c54f91$Blat.v2.4$f6e0b160@zahav.net.il> <20050503034604.GA437@nevyn.them.org> <01c55017$Blat.v2.4$3cb51f20@zahav.net.il> <20050503195650.GD25356@white> <01c55025$Blat.v2.4$00e755e0@zahav.net.il> <20050503213911.GB16440@trixie.casa.cgf.cx> <20050503222401.GA10377@nevyn.them.org> <20050503222647.GA19896@trixie.casa.cgf.cx> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050503222647.GA19896@trixie.casa.cgf.cx> User-Agent: Mutt/1.3.28i X-SW-Source: 2005-05/txt/msg00100.txt.bz2 On Tue, May 03, 2005 at 06:26:47PM -0400, Christopher Faylor wrote: > On Tue, May 03, 2005 at 06:24:01PM -0400, Daniel Jacobowitz wrote: > >On Tue, May 03, 2005 at 05:39:11PM -0400, Christopher Faylor wrote: > >> Anyway, it seems like the mingw port should be using GetFullPathName() > >> in gdb_realpath(). > > > >libiberty/lbasename.h: > > > > /* cygwin has realpath, so it won't get here. */ > ># if defined (_WIN32) > ># define WIN32_LEAN_AND_MEAN > ># include /* for GetFullPathName */ > ># endif > > > >So we call Cygwin's realpath or Window's GetFullPathName if we fall > >through to the lrealpath call. > > > >I don't know any of this affects DJGPP... > > Ah. Sorry. I didn't dig far enough. > > So, I guess I don't understand Eli's comments, then. I begin to make up a patch, and realized that the issue below needs to be resolved before anything can be done. Basically, Eli believes it is possible for GDB to return in the fullname field, a file name that is not absolute. Two examples were \abc or d:foo. He also mentioned that he might have once even seen a relative path. http://sources.redhat.com/ml/gdb-patches/2005-05/msg00091.html If what Eli believes is true (a point which I think is not worth debating, it could go either depending on the input to GDB), then there is 2 philosophies the testsuite can take to validating the fullname: - Use .* as a regex and say anthing goes - Use a regex that represents absolute paths. When this breaks, fix the fullname machinery. Does anyone have an opinion on what is a better approach? My humble opinion is to say that fullname should be an absolute path. If there is a valid argument for why it is impossible to get an absolute path from a fullname, then the first approach must be taken. Thanks, Bob Rossi