On 2/8/06, René Berber <[EMAIL PROTECTED]> wrote:
>
> I read the log and configure, the check is like this:
>
> #include <sys/types.h>
> #include <netdb.h>
>
> int
> main ()
> {
>
> struct hostent *hp;
> struct hostent h;
> char *name;
> char buffer[10];
> int  h_errno;
> hp = gethostbyname_r(name, &h, buffer, 10, &h_errno);
>
>   ;
>   return 0;
> }
>
> I would say that is very explicit use of h_errno.

Yes, but not the same as how ClamAV uses it. In this case, h_error is
a local variable, so of course the symbol resolves correctly. In real
code such as ClamAV, h_error is defined in system header files as an
external variable or a function.

That test is perfectly ok for testing how many arguments
gethostbyname_r() takes, however.

Jeff D
_______________________________________________
http://lurker.clamav.net/list/clamav-users.html

Reply via email to