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 "—">]>
5 - Copyright (C) 2004, 2005, 2007, 2014 Internet Systems Consortium, Inc. ("ISC")
6 - Copyright (C) 2000, 2001 Internet Software Consortium.
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.
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.
24 <date>June 18, 2007</date>
28 <refentrytitle>lwres_config</refentrytitle>
29 <manvolnum>3</manvolnum>
30 <refmiscinfo>BIND9</refmiscinfo>
39 <holder>Internet Systems Consortium, Inc. ("ISC")</holder>
44 <holder>Internet Software Consortium.</holder>
49 <refname>lwres_conf_init</refname>
50 <refname>lwres_conf_clear</refname>
51 <refname>lwres_conf_parse</refname>
52 <refname>lwres_conf_print</refname>
53 <refname>lwres_conf_get</refname>
54 <refpurpose>lightweight resolver configuration</refpurpose>
59 <funcsynopsisinfo>#include <lwres/lwres.h></funcsynopsisinfo>
63 <function>lwres_conf_init</function></funcdef>
64 <paramdef>lwres_context_t *<parameter>ctx</parameter></paramdef>
69 <function>lwres_conf_clear</function></funcdef>
70 <paramdef>lwres_context_t *<parameter>ctx</parameter></paramdef>
75 <function>lwres_conf_parse</function></funcdef>
76 <paramdef>lwres_context_t *<parameter>ctx</parameter></paramdef>
77 <paramdef>const char *<parameter>filename</parameter></paramdef>
82 <function>lwres_conf_print</function></funcdef>
83 <paramdef>lwres_context_t *<parameter>ctx</parameter></paramdef>
84 <paramdef>FILE *<parameter>fp</parameter></paramdef>
89 <function>lwres_conf_get</function></funcdef>
90 <paramdef>lwres_context_t *<parameter>ctx</parameter></paramdef>
96 <title>DESCRIPTION</title>
98 <para><function>lwres_conf_init()</function>
100 <type>lwres_conf_t</type>
101 structure for lightweight resolver context
102 <parameter>ctx</parameter>.
105 <para><function>lwres_conf_clear()</function>
106 frees up all the internal memory used by
108 <type>lwres_conf_t</type>
109 structure in resolver context
110 <parameter>ctx</parameter>.
113 <para><function>lwres_conf_parse()</function>
115 <parameter>filename</parameter>
116 and parses it to initialise the resolver context
117 <parameter>ctx</parameter>'s
118 <type>lwres_conf_t</type>
122 <para><function>lwres_conf_print()</function>
124 <type>lwres_conf_t</type>
125 structure for resolver context
126 <parameter>ctx</parameter>
129 <parameter>fp</parameter>.
134 <title>RETURN VALUES</title>
136 <para><function>lwres_conf_parse()</function>
137 returns <errorcode>LWRES_R_SUCCESS</errorcode>
138 if it successfully read and parsed
139 <parameter>filename</parameter>.
140 It returns <errorcode>LWRES_R_FAILURE</errorcode>
141 if <parameter>filename</parameter>
142 could not be opened or contained incorrect
146 <para><function>lwres_conf_print()</function>
147 returns <errorcode>LWRES_R_SUCCESS</errorcode>
148 unless an error occurred when converting the network addresses to a
149 numeric host address string.
150 If this happens, the function returns
151 <errorcode>LWRES_R_FAILURE</errorcode>.
155 <title>SEE ALSO</title>
157 <refentrytitle>stdio</refentrytitle><manvolnum>3</manvolnum>
160 <refentrytitle>resolver</refentrytitle><manvolnum>5</manvolnum>
166 <para><filename>/etc/resolv.conf</filename>