From owner-freebsd-hackers Mon Aug 18 15:30:29 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id PAA22214 for hackers-outgoing; Mon, 18 Aug 1997 15:30:29 -0700 (PDT) Received: from shell.firehouse.net (brian@shell.firehouse.net [209.42.203.45]) by hub.freebsd.org (8.8.5/8.8.5) with ESMTP id PAA22194; Mon, 18 Aug 1997 15:30:20 -0700 (PDT) Received: from localhost (brian@localhost) by shell.firehouse.net (8.8.5/8.8.5) with SMTP id SAA04176; Mon, 18 Aug 1997 18:29:33 -0400 (EDT) Date: Mon, 18 Aug 1997 18:29:32 -0400 (EDT) From: Brian Mitchell To: Nate Williams cc: "Jordan K. Hubbard" , hackers@FreeBSD.ORG Subject: Re: [Fwd: Re: Please Help Me Understand dlopen()] In-Reply-To: <199708182158.PAA03256@rocky.mt.sri.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk On Mon, 18 Aug 1997, Nate Williams wrote: > > Hmmm - any comments, ld hackers? > > > > The freeBSD dlsym() is - as far as I know - the only dlsym() > > implementation that doesn't search for _funktion() ... > > Here's a quick and dirty patch that implements it. I tested it locally > w/out any problems, but it has lots of possible problems. openbsd's is another that does not look for underscores. freebsd's has a few other minor holes too. If you dlsym() a nonexistant symbol, freebsd (in 2.2.1 atleast) returns a NULL pointer but does not (as it should) set the dlerror() errorcode. > > 1) If fails to prepend another underscore if the symbol already is > underscored. > 2) I haven't tested it enough on the entire system. > 3) It might not be the correct solution. > > > I also complained about dlopen() not searching LD_LIBRARY_PATH. > > I didn't even attempt to look at this. > > > Nate >