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_hstrerror</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_herror</refname>
50 <refname>lwres_hstrerror</refname>
51 <refpurpose>lightweight resolver error message generation</refpurpose>
55 <funcsynopsisinfo>#include <lwres/netdb.h></funcsynopsisinfo>
59 <function>lwres_herror</function></funcdef>
60 <paramdef>const char *<parameter>s</parameter></paramdef>
65 <function>lwres_hstrerror</function></funcdef>
66 <paramdef>int <parameter>err</parameter></paramdef>
72 <title>DESCRIPTION</title>
74 <para><function>lwres_herror()</function>
75 prints the string <parameter>s</parameter> on
76 <type>stderr</type> followed by the string generated by
77 <function>lwres_hstrerror()</function> for the error code stored
78 in the global variable <constant>lwres_h_errno</constant>.
81 <para><function>lwres_hstrerror()</function>
82 returns an appropriate string for the error code gievn by
83 <parameter>err</parameter>. The values of the error codes and
84 messages are as follows:
88 <term><errorcode>NETDB_SUCCESS</errorcode></term>
90 <para><errorname>Resolver Error 0 (no error)</errorname>
95 <term><errorcode>HOST_NOT_FOUND</errorcode></term>
97 <para><errorname>Unknown host</errorname>
102 <term><errorcode>TRY_AGAIN</errorcode></term>
104 <para><errorname>Host name lookup failure</errorname>
109 <term><errorcode>NO_RECOVERY</errorcode></term>
111 <para><errorname>Unknown server error</errorname>
116 <term><errorcode>NO_DATA</errorcode></term>
118 <para><errorname>No address associated with name</errorname>
127 <title>RETURN VALUES</title>
129 The string <errorname>Unknown resolver error</errorname> is returned by
130 <function>lwres_hstrerror()</function>
132 <constant>lwres_h_errno</constant>
133 is not a valid error code.
137 <title>SEE ALSO</title>
139 <refentrytitle>herror</refentrytitle><manvolnum>3</manvolnum>
143 <refentrytitle>lwres_hstrerror</refentrytitle><manvolnum>3</manvolnum>