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

AI_ADDRCONFIG in libldap/os-ip.c on solaris9



Hi all,

I am compiling OpenLDAP 2.2.15 on Solaris 9. When I run 'make test',
the first test fails with 'ldap_bind: Can't contact LDAP server (-1)'.

I did some digging and found that it is the ai_flags member of the
hints structure in libldap that is the problem. There was a similar
thread on 11 August, Tony B. had a similar (exactly the same?) problem
on AIX 5.1 (Bind Fails on AIX 5.1 due to getaddrinfo parm). Howard
chalked the problem up to a "rather broken getaddrinfo()" on AIX 5.1.
However, in December, 2003 Howard asked on the development list what the
purpose of using AI_ADDRCONFIG was as on netbsd 6.1, it is a flag that
is valid for the getipnodebyname structure (RE: commit:
ldap/libraries/libldap os-ip.c). Well, guess what ... on Solaris 9, that
is also the case -- it is a valid flag for getipnodebyname and _not_ for
hints. AI_ADDRCONFIG does not seem to be used on Linux (at least on the
distros I use).

So, do we have three widely used OSes (OK, so maybe AIX isn't exactly
"widely used"!) that have a "broken getaddrinfo()", or is this something
that needs fixing in OpenLDAP? An answer to Howard's question in
December, by the way, is not to be found in the list archives. So, I
would like to know, what was AI_ADDRCONFIG put in for if it is going to
mandate not using a perfectly good OS version of getaddrinfo() and, on
_what_ OS is this actually useful? Is getaddrinfo() broken, or is
op-ip.c broken?

I did, of course try setting 'ac_cv_func_getaddrinfo=no' as Howard
suggested to Tony, and it works as long as I do not try to enable IPv6
(sometinig I am experimenting with on my local net.)

Thanks, Mike.