From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32692 invoked by alias); 20 Feb 2003 21:15:25 -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 29608 invoked from network); 20 Feb 2003 21:13:28 -0000 Received: from unknown (HELO mx1.redhat.com) (172.16.49.200) by 172.16.49.205 with SMTP; 20 Feb 2003 21:13:28 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.11.6/8.11.6) with ESMTP id h1KLCnN32693; Thu, 20 Feb 2003 16:12:49 -0500 Received: from post-office.corp.redhat.com (post-office.corp.redhat.com [172.16.52.227]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id h1KLCnf24096; Thu, 20 Feb 2003 16:12:49 -0500 Received: from greed.delorie.com (dj.cipe.redhat.com [10.0.0.222]) by post-office.corp.redhat.com (8.11.6/8.11.6) with ESMTP id h1KLCmN20427; Thu, 20 Feb 2003 16:12:49 -0500 Received: (from dj@localhost) by greed.delorie.com (8.11.6/8.11.6) id h1KLClG12970; Thu, 20 Feb 2003 16:12:47 -0500 Date: Thu, 20 Feb 2003 21:15:00 -0000 Message-Id: <200302202112.h1KLClG12970@greed.delorie.com> From: DJ Delorie To: drow@mvista.com CC: mstump@apple.com, pfeifer@dbai.tuwien.ac.at, gcc-patches@gcc.gnu.org, binutils@sources.redhat.com, gdb-patches@sources.redhat.com In-reply-to: <20030220204639.GA22900@nevyn.them.org> (message from Daniel Jacobowitz on Thu, 20 Feb 2003 15:46:39 -0500) Subject: Re: PATCH[libiberty] for Re: Mainline: C++ include files not found! References: <20030215135157.GA23004@nevyn.them.org> <20030220182105.GA7787@nevyn.them.org> <200302202026.h1KKQk711991@greed.delorie.com> <20030220204639.GA22900@nevyn.them.org> X-SW-Source: 2003-02/txt/msg00498.txt.bz2 > My initial reluctance was that readlink isn't guaranteed to give us > something that we can append to the dirname and access. And I'd > need to drag in both stat and readlink, and some bits for > HOST_EXECUTABLE_SUFFIX that I'm not entirely sure of. I had at one point written a semi-portable canonicalize_file_name() that did all that, but the reason I wrote it went away, so I dropped it. > Would you rather I add this, or can we leave it until someone needs > this on DJGPP? It will work well enough on DJGPP without it, so I wouldn't bother. > Optionally returning filename seems risky to me, personally. I'm thinking that most uses of this function will call it once at program startup and not even need to free the malloc'd pointer. I guess it doesn't matter either way. > You've got a good point on the xmalloc thing. How about use malloc > and return NULL on allocation failure? And strdup instead of > xstrdup. That would be better.