It specifies the default number of retries per a name server.
This makes the code consistent with the manpage and allows to
kill another constant in res_init.c that should have been a
#define'd parameter. (This appears to be a case when the manpage
was better than the code, so the latter was to be fixed.)
PR: bin/62139 (in the audit trail)
The getaddrinfo(3), getipnodebyname(3) and resolver(3) can coincide now
with what should be totally reentrant, and h_errno values will now
be preserved correctly, but this does not affect interfaces such as
gethostbyname(3) which are still mostly non-reentrant.
In all of these relevant functions, the thread-safety has been pushed
down as far as it seems possible right now. This means that operations
that are selected via nsdispatch(3) (i.e. files, yp, dns) are protected
still under global locks that getaddrinfo(3) defines, but where possible
the locking is greatly reduced. The most noticeable improvement is
that multiple DNS lookups can now be run at the same time, and this
shows major improvement in performance of DNS-lookup threaded programs,
and solves the "Mozilla tab serialization" problem.
No single-threaded applications need to be recompiled. Multi-threaded
applications that reference "_res" to change resolver(3) options will
need to be recompiled, and ones which reference "h_errno" will also
if they desire the correct h_errno values. If the applications already
understood that _res and h_errno were not thread-safe and had their own
locking, they will see no performance improvement but will not
actually break in any way.
Please note that when NSS modules are used, or when nsdispatch(3)
defaults to adding any lookups of its own to the individual libc
_nsdispatch() calls, those MUST be reentrant as well.
# This appears to not break X11, but I'm having problems compiling the
# glide part of the server with or without this patch, so I can't tell
# for sure.
IPv6 transport-ready resolvers/DNS servers. Need careful configuration
when enable it. (default config is not affected).
See manpage for details.
XXX visible symbol __res_opt() is added, however, it is not supposed to be
called from outside, libc minor is not bumped.
Obtained from: KAME/NetBSD
externed in netdb.h - where all of its #define values
live. If anything requires h_errno here (nothing in
/usr/src seems to) it's almost definitely broken.
<resolv.h>. This breaks user ppp at least, and goodness knows how
many ports. :-(
This a bit of a hack, but is probably simpler than duplicating the
typedefs and protecting them from each other.
Also, remove some temporary XXX notes that I forgot to remove before.
since it has far wider impact than hostname lookups (including passwords).
Note that this has more ugly symbol hiding and binary compatability hacks
that can go away the second we bump majors.
Obtained from: Mostly from diff against ISC bind-8.1.2 sources
This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.
Boy, I'm glad we're not using sup anymore. This update would have been
insane otherwise.
Note: this was done by selective patching from diffs by hand, in order
to not conflict with the 4.4BSD base code. Beta9 was done the same way.
Obtained from: Paul Vixie <paul@vix.com>