History log of /freebsd-10.1-release/lib/libc/net/gethostbyname.3
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 272461 02-Oct-2014 gjb

Copy stable/10@r272459 to releng/10.1 as part of
the 10.1-RELEASE process.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

# 256281 10-Oct-2013 gjb

Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


# 254484 18-Aug-2013 pjd

Consistently use 'af' as an argument name for address family.
Now both gethostbyname2(3) and gethostbyaddr(3) use the same argument name.
The same argument name is also used in implementations of those functions.


# 165903 08-Jan-2007 imp

Per Regents of the University of Calfornia letter, remove advertising
clause.

# If I've done so improperly on a file, please let me know.


# 163982 04-Nov-2006 lawrance

Document return values for res_query and res_search.
h_errno is not an extern int, just a macro providing an integer lvalue.

PR: doc/50573
Submitted by: Ronald F.Guilmette <rfg@monkeys.com>
Reviewed by: trhodes
MFC after: 3 days


# 162385 17-Sep-2006 ru

Markup fixes.


# 158477 12-May-2006 ume

Fix gethostbyaddr() prototype to conform to IEEE Std 1003.1:

http://www.opengroup.org/onlinepubs/009695399/functions/gethostbyaddr.html

gethostbyaddr_r() is changed as well.
It breaks ABI backward compatibility on 64 bit arch. So, we fix it
on 32 bit arch only for now.

Reported by: Rostislav Krasny <rosti.bsd@gmail.com>


# 145633 28-Apr-2005 ume

make gethostby*() thread-safe.


# 145550 26-Apr-2005 ume

add IPv6 awareness for NIS query of gethostby*().

Inspired by: NetBSD


# 131504 02-Jul-2004 ru

Mechanically kill hard sentence breaks.


# 126243 25-Feb-2004 green

Make the resolver(3) and many associated interfaces much more reentrant.
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.


# 116022 08-Jun-2003 charnier

.Xr -> .Lb for librairy. There is no manual page corresponding to .Xr.


# 110440 06-Feb-2003 charnier

The .Fn function


# 108087 19-Dec-2002 ru

mdoc(7) police: "The .Fa argument.".


# 108037 18-Dec-2002 ru

mdoc(7) police: "The .Fn function".


# 89362 14-Jan-2002 ru

yp(4) -> yp(8).

PR: docs/30797


# 84306 01-Oct-2001 ru

mdoc(7) police: Use the new .In macro for #include statements.


# 81283 08-Aug-2001 ru

Urge the reader to start using getaddrinfo(3) and getnameinfo(3)
protocol-independant functions that don't use static memory area.

Suggested by: nik
Liked by: ume, brian


# 79754 15-Jul-2001 dd

Remove whitespace at EOL.


# 79531 10-Jul-2001 ru

mdoc(7) police: removed HISTORY info from the .Os call.


# 76620 15-May-2001 ru

mdoc(7) police: sort xrefs.


# 76369 08-May-2001 alex

gethostbyname2() can't do AF_INET6 lookups over NIS.
getaddrinfo(3) must be used.

Submitted by: ume


# 76076 27-Apr-2001 archie

Add getaddrinfo(3) to the "SEE ALSO" list.


# 72314 10-Feb-2001 ru

mdoc(7) police: polishing.


# 72251 09-Feb-2001 nik

Describe the arguments to gethostbyaddr.

PR: docs/24225
Submitted by: Joakim Henriksson <jurduth@ludd.luth.se>
Patch from: ben


# 70974 12-Jan-2001 ru

mdoc(7) police: Ft/Vt now accept punctuation-type arguments.


# 70710 06-Jan-2001 alex

gethostbyname2() is able to lookup AF_INET6.

PR: 23823
Noticed by: Andrew Arensburger <arensb@ooblick.com>


# 65532 06-Sep-2000 nectar

Add nsswitch support. By creating an /etc/nsswitch.conf file, you can
configure FreeBSD so that various databases such as passwd and group can be
looked up using flat files, NIS, or Hesiod.

= Hesiod has been added to libc (see hesiod(3)).

= A library routine for parsing nsswitch.conf and invoking callback
functions as specified has been added to libc (see nsdispatch(3)).

= The following C library functions have been modified to use nsdispatch:
. getgrent, getgrnam, getgrgid
. getpwent, getpwnam, getpwuid
. getusershell
. getaddrinfo
. gethostbyname, gethostbyname2, gethostbyaddr
. getnetbyname, getnetbyaddr
. getipnodebyname, getipnodebyaddr, getnodebyname, getnodebyaddr

= host.conf has been removed from src/etc. rc.network has been modified
to warn that host.conf is no longer used at boot time. In addition, if
there is a host.conf but no nsswitch.conf, the latter is created at boot
time from the former.

Obtained from: NetBSD


# 59460 21-Apr-2000 phantom

Introduce ".Lb" macro to libc manpages.

More libraries manpages updates following.


# 51419 19-Sep-1999 phantom

Fix typo

PR: docs/13814
Submitted by: Alex Vasylenko <lxv@mix.nest.org>


# 50476 27-Aug-1999 peter

$Id$ -> $FreeBSD$


# 36692 06-Jun-1998 jkoshy

Spelling corrections.

PR: 6868
Submitted by: Josh Gilliam <josh@quick.net>


# 34817 23-Mar-1998 bde

(Ab)use .Vt instead of .Fd for a variable declaration.


# 26721 18-Jun-1997 charnier

Typo.


# 24006 18-Mar-1997 bde

Fixed missing function types in synopsis.


# 19302 01-Nov-1996 peter

Doc updates and cleanups made with the bind-4.9.4 update some time ago.
I thought I had committed these, but it seems not.


# 18824 08-Oct-1996 jdp

Fix an error in the description of "h_errno". Add "const" to a few
declarations to make them agree with the actual prototypes in <netdb.h>.


# 17955 30-Aug-1996 peter

back out last two changes, this caused the mandoc pages to be replaced by
man pages. I'll fold in the real changes in a seperate commit.


# 17917 29-Aug-1996 peter

The last commit failed part-way through, re-add the generated
resolver man pages.