[Date Prev][Date Next] [Chronological] [Thread] [Top]

PF_LOCAL in getaddrinfo (ldapi:///)



I was trying to compile OpenLDAP 2.0.11 with support for ldapi:///
which uses the PF_LOCAL family. However, I've discovered that
the PF_LOCAL entry in getaddrinfo is ifdef'd out in FreeBSD.

This is the relevant code for /usr/src/lib/libc/net/getaddrinfo.c

#if 0
	{ PF_LOCAL, 0, ANY, ANY, NULL, 0x01 },
#endif

This causes a getaddrinfo call made by openldap with hints.ai_family
set to AF_LOCAL to fail with an "ai_family not supported" error
message.

I tried it in Solaris and get the same error (I don't have Solaris's
source code so I coulnd't check if it was not defined).

Is this an error in the way OpenLDAP uses getaddrinfo or is there
a reason for the OS's not supporting AF_LOCAL in calls to getaddrinfo?
How can I fix this? Should I just unifdef PF_LOCAL in my OS's getaddrinfo
or comment out the getaddrinfo in daemon.c?

Thanks,

-Oscar

-- 
pgp public key: finger obonilla@galileo.edu
pgp fingerprint: 9735 2F52 D499 17E2 D03B  5960 241D 09EA 349F 923E