Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 28 Oct 2005 00:35:00 -0700 (PDT)
From:      Rob <spamrefuse@yahoo.com>
To:        Igor Robul <igorr@speechpro.com>, FreeBSD questions <freebsd-questions@freebsd.org>
Subject:   Re: math/grace port: "libXcursor.so.1.0" not found ?? [SOLVED]
Message-ID:  <20051028073500.35399.qmail@web36210.mail.mud.yahoo.com>
In-Reply-To: <4361C4C3.1080806@speechpro.com>

next in thread | previous in thread | raw e-mail | index | archive | help


--- Igor Robul <igorr@speechpro.com> wrote:

> Rob wrote:
> 
> >--- Igor Robul <igorr@speechpro.com> wrote:
> >  
> >
> >First:
> >NULL return from dlsym() does not always imply an
> >error. dlsym() can return NULL because it has an
> >empty list, but this does not set the error
> >indicator of dlerror(), because it is not an error.
> >However, if an error occurs, dlsym() has NULL as
> >a return (that's probably most sensible return).
> >  
> >
>  From manual page:
> 
> The dlsym() function returns a null pointer if the
> symbol cannot be 
> found, and sets an error condition
>  which may be queried with dlerror().

This is a matter of symantic and logic.

I /can/ read this as follows:

If the symbol cannot be found, then dlsym() returns
a null pointer *AND* sets the error condition.

However, dlsym() can also return the null pointer,
*WITHOUT* setting the error condition. The latter
case seems to be better specified in the Linux
manpages of dlsym(). Hence the conflict between
FreeBSD and Linux/Grace, I guess.

Rob.



	
		
__________________________________ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.yahoo.com



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20051028073500.35399.qmail>