]> CyberLeo.Net >> Repos - FreeBSD/releng/9.2.git/blob - contrib/bind9/lib/lwres/man/lwres_inetntop.docbook
- Copy stable/9 to releng/9.2 as part of the 9.2-RELEASE cycle.
[FreeBSD/releng/9.2.git] / contrib / bind9 / lib / lwres / man / lwres_inetntop.docbook
1 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
2                "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
3                [<!ENTITY mdash "&#8212;">]>
4 <!--
5  - Copyright (C) 2004, 2005, 2007, 2012  Internet Systems Consortium, Inc. ("ISC")
6  - Copyright (C) 2000, 2001  Internet Software Consortium.
7  -
8  - Permission to use, copy, modify, and/or distribute this software for any
9  - purpose with or without fee is hereby granted, provided that the above
10  - copyright notice and this permission notice appear in all copies.
11  -
12  - THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
13  - REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
14  - AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
15  - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
16  - LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
17  - OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
18  - PERFORMANCE OF THIS SOFTWARE.
19 -->
20
21 <!-- $Id$ -->
22 <refentry>
23
24   <refentryinfo>
25     <date>Jun 30, 2000</date>
26   </refentryinfo>
27
28   <refmeta>
29     <refentrytitle>lwres_inetntop</refentrytitle>
30     <manvolnum>3</manvolnum>
31     <refmiscinfo>BIND9</refmiscinfo>
32   </refmeta>
33
34   <docinfo>
35     <copyright>
36       <year>2004</year>
37       <year>2005</year>
38       <year>2007</year>
39       <year>2012</year>
40       <holder>Internet Systems Consortium, Inc. ("ISC")</holder>
41     </copyright>
42     <copyright>
43       <year>2000</year>
44       <year>2001</year>
45       <holder>Internet Software Consortium.</holder>
46     </copyright>
47   </docinfo>
48
49   <refnamediv>
50     <refname>lwres_net_ntop</refname>
51     <refpurpose>lightweight resolver IP address presentation</refpurpose>
52   </refnamediv>
53   <refsynopsisdiv>
54     <funcsynopsis>
55 <funcsynopsisinfo>#include &lt;lwres/net.h&gt;</funcsynopsisinfo>
56 <funcprototype>
57         <funcdef>
58 const char *
59 <function>lwres_net_ntop</function></funcdef>
60         <paramdef>int <parameter>af</parameter></paramdef>
61         <paramdef>const void *<parameter>src</parameter></paramdef>
62         <paramdef>char *<parameter>dst</parameter></paramdef>
63         <paramdef>size_t <parameter>size</parameter></paramdef>
64       </funcprototype>
65 </funcsynopsis>
66   </refsynopsisdiv>
67
68   <refsect1>
69     <title>DESCRIPTION</title>
70
71     <para><function>lwres_net_ntop()</function>
72       converts an IP address of protocol family
73       <parameter>af</parameter> &mdash; IPv4 or IPv6 &mdash; at
74       location <parameter>src</parameter> from network format to its
75       conventional representation as a string.  For IPv4 addresses,
76       that string would be a dotted-decimal.  An IPv6 address would be
77       represented in colon notation as described in RFC1884.
78     </para>
79
80     <para>
81       The generated string is copied to <parameter>dst</parameter>
82       provided
83       <parameter>size</parameter> indicates it is long enough to
84       store the
85       ASCII representation of the address.
86     </para>
87
88   </refsect1>
89   <refsect1>
90     <title>RETURN VALUES</title>
91
92     <para>
93       If successful, the function returns <parameter>dst</parameter>:
94       a pointer to a string containing the presentation format of the
95       address.  <function>lwres_net_ntop()</function> returns
96       <type>NULL</type> and sets the global variable
97       <constant>errno</constant> to <errorcode>EAFNOSUPPORT</errorcode> if
98       the protocol family given in <parameter>af</parameter> is
99       not
100       supported.
101     </para>
102
103   </refsect1>
104   <refsect1>
105     <title>SEE ALSO</title>
106     <para><citerefentry>
107         <refentrytitle>RFC1884</refentrytitle>
108       </citerefentry>,
109       <citerefentry>
110         <refentrytitle>inet_ntop</refentrytitle><manvolnum>3</manvolnum>
111       </citerefentry>,
112       <citerefentry>
113         <refentrytitle>errno</refentrytitle><manvolnum>3</manvolnum>
114       </citerefentry>.
115     </para>
116   </refsect1>
117 </refentry><!--
118  - Local variables:
119  - mode: sgml
120  - End:
121 -->