Merge from vendor branch SENDMAIL:
[dragonfly.git] / contrib / bind-9.2.4rc7 / lib / lwres / man / lwres_inetntop.3
1 .\" Copyright (C) 2004  Internet Systems Consortium, Inc. ("ISC")
2 .\" Copyright (C) 2000, 2001  Internet Software Consortium.
3 .\"
4 .\" Permission to use, copy, modify, and distribute this software for any
5 .\" purpose with or without fee is hereby granted, provided that the above
6 .\" copyright notice and this permission notice appear in all copies.
7 .\"
8 .\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
9 .\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
10 .\" AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
11 .\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
12 .\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
13 .\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
14 .\" PERFORMANCE OF THIS SOFTWARE.
15 .\"
16 .\" $Id: lwres_inetntop.3,v 1.12.2.2 2004/03/15 04:45:04 marka Exp $
17 .\"
18 .TH "LWRES_INETNTOP" "3" "Jun 30, 2000" "BIND9" ""
19 .SH NAME
20 lwres_net_ntop \- lightweight resolver IP address presentation
21 .SH SYNOPSIS
22 \fB#include <lwres/net.h>
23 .sp
24 .na
25 const char *
26 lwres_net_ntop(int af, const void *src, char *dst, size_t size);
27 .ad
28 \fR
29 .SH "DESCRIPTION"
30 .PP
31 \fBlwres_net_ntop()\fR converts an IP address of
32 protocol family \fIaf\fR \(em IPv4 or IPv6 \(em
33 at location \fIsrc\fR from network format to its
34 conventional representation as a string. For IPv4 addresses, that
35 string would be a dotted-decimal. An IPv6 address would be
36 represented in colon notation as described in RFC1884.
37 .PP
38 The generated string is copied to \fIdst\fR provided
39 \fIsize\fR indicates it is long enough to store the
40 ASCII representation of the address.
41 .SH "RETURN VALUES"
42 .PP
43 If successful, the function returns \fIdst\fR:
44 a pointer to a string containing the presentation format of the
45 address. \fBlwres_net_ntop()\fR returns
46 \fBNULL\fR and sets the global variable
47 errno to EAFNOSUPPORT if
48 the protocol family given in \fIaf\fR is not
49 supported.
50 .SH "SEE ALSO"
51 .PP
52 \fBRFC1884\fR,
53 \fBinet_ntop\fR(3),
54 \fBerrno\fR(3).