reSIProcate
SIP stack, Dialog Usage Manager and related libraries
Loading...
Searching...
No Matches
ares_strerror.c
Go to the documentation of this file.
1
/* Copyright 1998 by the Massachusetts Institute of Technology.
2
*
3
* Permission to use, copy, modify, and distribute this
4
* software and its documentation for any purpose and without
5
* fee is hereby granted, provided that the above copyright
6
* notice appear in all copies and that both that copyright
7
* notice and this permission notice appear in supporting
8
* documentation, and that the name of M.I.T. not be used in
9
* advertising or publicity pertaining to distribution of the
10
* software without specific, written prior permission.
11
* M.I.T. makes no representations about the suitability of
12
* this software for any purpose. It is provided "as is"
13
* without express or implied warranty.
14
*/
15
16
#include "
rutil/ResipAssert.h
"
17
#include "
ares.h
"
18
19
const
char
*
ares_strerror
(
int
code)
20
{
21
/* A future implementation may want to handle internationalization.
22
* For now, just return a string literal from a table.
23
*/
24
const
char
*
errtext
[] = {
25
"Successful completion"
,
26
"DNS server returned answer with no data"
,
27
"DNS server claims query was misformatted"
,
28
"DNS server returned general failure"
,
29
"Domain name not found"
,
30
"DNS server does not implement requested operation"
,
31
"DNS server refused query"
,
32
"Misformatted DNS query"
,
33
"Misformatted domain name"
,
34
"Unsupported address family"
,
35
"Misformatted DNS reply"
,
36
"Could not contact DNS servers"
,
37
"Timeout while contacting DNS servers"
,
38
"End of file"
,
39
"Error reading file"
,
40
"Out of memory"
,
41
"Destructing"
42
};
43
44
resip_assert
(code >= 0 && code < (
sizeof
(
errtext
) /
sizeof
(*
errtext
)));
45
46
return
errtext
[code];
47
}
ResipAssert.h
resip_assert
#define resip_assert(x)
This file needs to work for both C and C++ code.
Definition
ResipAssert.h:107
ares.h
ares_strerror
const char * ares_strerror(int code)
Definition
ares_strerror.c:19
list
void list()
Definition
userAdmin.cxx:66
rutil
dns
ares
ares_strerror.c
Generated by
1.9.8