Date: Mon, 18 Aug 1997 16:38:30 -0600 (MDT) From: Nate Williams <nate@mt.sri.com> To: Brian Mitchell <brian@firehouse.net> Cc: Nate Williams <nate@mt.sri.com>, "Jordan K. Hubbard" <jkh@freebsd.org>, hackers@freebsd.org Subject: Re: [Fwd: Re: Please Help Me Understand dlopen()] Message-ID: <199708182238.QAA03400@rocky.mt.sri.com> In-Reply-To: <Pine.BSI.3.95.970818182539.4166A-100000@shell.firehouse.net> References: <199708182158.PAA03256@rocky.mt.sri.com> <Pine.BSI.3.95.970818182539.4166A-100000@shell.firehouse.net>
next in thread | previous in thread | raw e-mail | index | archive | help
> > > > 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. Umm, yes it does. At least, it does in the version in 2.2. >From ld/rtld/rtld.c: if (np == NULL) { generror("Undefined symbol"); return NULL; generror sets the dlerror() error string. I'm working on a better fix than I sent out now, but it's not as easy as it could be due to the way the code is laid out. Nate
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199708182238.QAA03400>