From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10094 invoked by alias); 14 Apr 2010 21:52:49 -0000 Received: (qmail 10085 invoked by uid 22791); 14 Apr 2010 21:52:48 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=BAYES_00,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from sibelius.xs4all.nl (HELO glazunov.sibelius.xs4all.nl) (83.163.83.176) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 14 Apr 2010 21:52:44 +0000 Received: from glazunov.sibelius.xs4all.nl (kettenis@localhost [127.0.0.1]) by glazunov.sibelius.xs4all.nl (8.14.3/8.14.3) with ESMTP id o3ELqXIG016643; Wed, 14 Apr 2010 23:52:33 +0200 (CEST) Received: (from kettenis@localhost) by glazunov.sibelius.xs4all.nl (8.14.3/8.14.3/Submit) id o3ELqWUG014091; Wed, 14 Apr 2010 23:52:32 +0200 (CEST) Date: Wed, 14 Apr 2010 21:52:00 -0000 Message-Id: <201004142152.o3ELqWUG014091@glazunov.sibelius.xs4all.nl> From: Mark Kettenis To: dje@google.com CC: gdb-patches@sourceware.org In-reply-to: <20100414212745.75E5B84396@ruffy.mtv.corp.google.com> (dje@google.com) Subject: Re: [commit] Strip DOS drive letter in openp References: <20100414212745.75E5B84396@ruffy.mtv.corp.google.com> 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: 2010-04/txt/msg00457.txt.bz2 > Date: Wed, 14 Apr 2010 14:27:45 -0700 (PDT) > From: dje@google.com (Doug Evans) > > Hi. > > I've checked in this patch which strips a DOS drive spec if present > before concatenating string with the search path. > > This is in reference to this thread: > http://sourceware.org/ml/gdb-patches/2010-04/msg00110.html > and in particular: > http://sourceware.org/ml/gdb-patches/2010-04/msg00277.html > > 2010-04-14 Doug Evans > > * source.c (openp): Strip DOS drive letter if present before > concatenating string to search path. > > Index: source.c > =================================================================== > RCS file: /cvs/src/src/gdb/source.c,v > retrieving revision 1.109 > diff -u -p -r1.109 source.c > --- source.c 8 Apr 2010 21:08:39 -0000 1.109 > +++ source.c 14 Apr 2010 21:18:59 -0000 > @@ -724,6 +724,10 @@ openp (const char *path, int opts, const > goto done; > } > > + /* For dos paths, d:/foo -> /foo, and d:foo -> foo. */ > + if (HAS_DRIVE_SPEC (string)) > + string = STRIP_DRIVE_SPEC (string); > + Eh, where does HAS_DRIVE_SPEC come from?