lwres_gai_strerror.html revision 5fa6a064b8301e4f274bd132fd577def59e4fb4c
369N/A<!--
369N/A - Copyright (C) 2004, 2005, 2007, 2014 Internet Systems Consortium, Inc. ("ISC")
369N/A - Copyright (C) 2000, 2001 Internet Software Consortium.
369N/A -
369N/A - Permission to use, copy, modify, and/or distribute this software for any
369N/A - purpose with or without fee is hereby granted, provided that the above
369N/A - copyright notice and this permission notice appear in all copies.
369N/A -
369N/A - THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
369N/A - REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
369N/A - AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
369N/A - INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
369N/A - LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
369N/A - OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
369N/A - PERFORMANCE OF THIS SOFTWARE.
369N/A-->
369N/A<!-- $Id$ -->
369N/A<html>
369N/A<head>
369N/A<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
5680N/A<title>lwres_gai_strerror</title>
5680N/A<meta name="generator" content="DocBook XSL Stylesheets V1.71.1">
5622N/A</head>
369N/A<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en">
5680N/A<a name="id2476282"></a><div class="titlepage"></div>
5680N/A<div class="refnamediv">
369N/A<h2>Name</h2>
369N/A<p>lwres_gai_strerror &#8212; print suitable error string</p>
369N/A</div>
844N/A<div class="refsynopsisdiv">
844N/A<h2>Synopsis</h2>
369N/A<div class="funcsynopsis">
5622N/A<pre class="funcsynopsisinfo">#include &lt;lwres/netdb.h&gt;</pre>
369N/A<table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0"><tr>
5680N/A<td><code class="funcdef">
369N/Achar *
5680N/A<b class="fsfunc">gai_strerror</b>(</code></td>
369N/A<td>int �</td>
5680N/A<td>
5680N/A<var class="pdparam">ecode</var><code>)</code>;</td>
5680N/A</tr></table>
5680N/A</div>
5680N/A</div>
5680N/A<div class="refsect1" lang="en">
5680N/A<a name="id2543372"></a><h2>DESCRIPTION</h2>
5680N/A<p><code class="function">lwres_gai_strerror()</code>
5680N/A returns an error message corresponding to an error code returned by
5680N/A <code class="function">getaddrinfo()</code>.
5680N/A The following error codes and their meaning are defined in
5680N/A <code class="filename">include/lwres/netdb.h</code>.
5680N/A </p>
5680N/A<div class="variablelist"><dl>
5680N/A<dt><span class="term"><span class="errorcode">EAI_ADDRFAMILY</span></span></dt>
5680N/A<dd><p>
5680N/A address family for hostname not supported
5680N/A </p></dd>
5680N/A<dt><span class="term"><span class="errorcode">EAI_AGAIN</span></span></dt>
5680N/A<dd><p>
5680N/A temporary failure in name resolution
5680N/A </p></dd>
5680N/A<dt><span class="term"><span class="errorcode">EAI_BADFLAGS</span></span></dt>
5680N/A<dd><p>
5680N/A invalid value for
5680N/A <code class="constant">ai_flags</code>
5680N/A </p></dd>
5680N/A<dt><span class="term"><span class="errorcode">EAI_FAIL</span></span></dt>
5680N/A<dd><p>
5680N/A non-recoverable failure in name resolution
5680N/A </p></dd>
5680N/A<dt><span class="term"><span class="errorcode">EAI_FAMILY</span></span></dt>
5680N/A<dd><p><code class="constant">ai_family</code> not supported
369N/A </p></dd>
369N/A<dt><span class="term"><span class="errorcode">EAI_MEMORY</span></span></dt>
369N/A<dd><p>
369N/A memory allocation failure
369N/A </p></dd>
369N/A<dt><span class="term"><span class="errorcode">EAI_NODATA</span></span></dt>
<dd><p>
no address associated with hostname
</p></dd>
<dt><span class="term"><span class="errorcode">EAI_NONAME</span></span></dt>
<dd><p>
hostname or servname not provided, or not known
</p></dd>
<dt><span class="term"><span class="errorcode">EAI_SERVICE</span></span></dt>
<dd><p>
servname not supported for <code class="constant">ai_socktype</code>
</p></dd>
<dt><span class="term"><span class="errorcode">EAI_SOCKTYPE</span></span></dt>
<dd><p><code class="constant">ai_socktype</code> not supported
</p></dd>
<dt><span class="term"><span class="errorcode">EAI_SYSTEM</span></span></dt>
<dd><p>
system error returned in errno
</p></dd>
</dl></div>
<p>
The message <span class="errorname">invalid error code</span> is returned if
<em class="parameter"><code>ecode</code></em>
is out of range.
</p>
<p><code class="constant">ai_flags</code>,
<code class="constant">ai_family</code>
and
<code class="constant">ai_socktype</code>
are elements of the
<span class="type">struct addrinfo</span>
used by
<code class="function">lwres_getaddrinfo()</code>.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2543588"></a><h2>SEE ALSO</h2>
<p><span class="citerefentry"><span class="refentrytitle">strerror</span>(3)</span>,
<span class="citerefentry"><span class="refentrytitle">lwres_getaddrinfo</span>(3)</span>,
<span class="citerefentry"><span class="refentrytitle">getaddrinfo</span>(3)</span>,
<span class="citerefentry"><span class="refentrytitle">RFC2133</span></span>.
</p>
</div>
</div></body>
</html>