isc_ipproto.3 revision 499b34cea04a46823d003d4c0520c8b03e8513cb
Copyright (C) 2000, 2001 Internet Software Consortium.

Permission to use, copy, modify, and distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.

THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM
DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL
INTERNET SOFTWARE CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING
FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
$Id: isc_ipproto.3,v 1.6 2001/01/09 21:47:57 bwelling Exp $
.Dd Jun 30, 2000 .Dt ISC_IPPROTO 3 .Os BIND9 9 .Sh NAME .Nm isc_net_probeipv4 , .Nm isc_net_probeipv6 .Nd protocol probe functions .Sh SYNOPSIS .Fd #include <config.h> .Fd #include <errno.h> .Fd #include <unistd.h> .Fd #include <isc/net.h> .Fd #include <isc/once.h> .Fd #include <isc/string.h> .Fd #include <isc/util.h> .Fo isc_net_probeipv4 .Fa void .Fc .Ft isc_result_t .Fo isc_net_probeipv4 .Fa void .Fc .Sh DESCRIPTION .Fn isc_net_probeipv4 and .Fn isc_net_probeipv6 check that the operating system support the IPv4 and IPv6 protocols respectively. .Sh RETURN VALUES .Fn isc_net_probeipv4 returns .Er ISC_R_SUCCESS if the IPv4 protocol is supported by the kernel and .Fn isc_net_probeipv6 returns .Er ISC_R_SUCCESS if the operating system supports IPv6. .Fn try_proto returns .Fn ISC_R_NOTFOUND if the chosen protocol family .Fa domain is not supported by the kernel. An error message is printed on .Dv stderr and .Er ISC_R_UNEXPECTED returned if another error occurred when the attempt was made to create the .Dv SOCK_STREAM socket. .Sh SEE ALSO .Xr socket 2 , .Xr ip 4 , .Xr ipv6 4 .