3
Cheap knock-off of libisc result table code. This is just a place-holder
4
until the actual libisc merge. */
7
* Copyright (c) 2004,2007 by Internet Systems Consortium, Inc. ("ISC")
8
* Copyright (c) 1999-2003 by Internet Software Consortium
10
* Permission to use, copy, modify, and distribute this software for any
11
* purpose with or without fee is hereby granted, provided that the above
12
* copyright notice and this permission notice appear in all copies.
14
* THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES
15
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
16
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR
17
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
18
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
19
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
20
* OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
22
* Internet Systems Consortium, Inc.
24
* Redwood City, CA 94063
28
* This software has been written for Internet Systems Consortium
29
* by Ted Lemon in cooperation with Vixie Enterprises and Nominum, Inc.
30
* To learn more about Internet Systems Consortium, see
31
* ``http://www.isc.org/''. To learn more about Vixie Enterprises,
32
* see ``http://www.vix.com''. To learn more about Nominum, Inc., see
33
* ``http://www.nominum.com''.
38
#include <omapip/omapip_p.h>
40
static const char *text[ISC_R_NRESULTS] = {
42
"out of memory", /* 1 */
44
"no available threads", /* 3 */
45
"address not available", /* 4 */
46
"address in use", /* 5 */
47
"permission denied", /* 6 */
48
"no pending connections", /* 7 */
49
"network unreachable", /* 8 */
50
"host unreachable", /* 9 */
51
"network down", /* 10 */
53
"connection refused", /* 12 */
54
"not enough free resources", /* 13 */
55
"end of file", /* 14 */
56
"socket already bound", /* 15 */
57
"task is done", /* 16 */
59
"already exists", /* 18 */
60
"ran out of space", /* 19 */
61
"operation canceled", /* 20 */
62
"sending events is not allowed", /* 21 */
63
"shutting down", /* 22 */
65
"unexpected end of input", /* 24 */
68
"not implemented", /* 27 */
69
"unbalanced parentheses", /* 28 */
71
"invalid file", /* 30 */
72
"bad base64 encoding", /* 31 */
73
"unexpected token", /* 32 */
74
"quota reached", /* 33 */
75
"unexpected error", /* 34 */
76
"already running", /* 35 */
77
"host unknown", /* 36 */
78
"protocol version mismatch", /* 37 */
79
"protocol error", /* 38 */
80
"invalid argument", /* 39 */
81
"not connected", /* 40 */
82
"data not yet available", /* 41 */
83
"object unchanged", /* 42 */
84
"more than one object matches key", /* 43 */
85
"key conflict", /* 44 */
86
"parse error(s) occurred", /* 45 */
87
"no key specified", /* 46 */
88
"zone TSIG key not known", /* 47 */
89
"invalid TSIG key", /* 48 */
90
"operation in progress", /* 49 */
91
"DNS format error", /* 50 */
92
"DNS server failed", /* 51 */
93
"no such domain", /* 52 */
94
"not implemented", /* 53 */
96
"domain already exists", /* 55 */
97
"RRset already exists", /* 56 */
98
"no such RRset", /* 57 */
99
"not authorized", /* 58 */
100
"not a zone", /* 59 */
101
"bad DNS signature", /* 60 */
102
"bad DNS key", /* 61 */
103
"clock skew too great", /* 62 */
104
"no root zone", /* 63 */
105
"destination address required", /* 64 */
106
"cross-zone update", /* 65 */
107
"no TSIG signature", /* 66 */
108
"not equal", /* 67 */
109
"connection reset by peer", /* 68 */
110
"unknown attribute" /* 69 */
113
const char *isc_result_totext (isc_result_t result)
115
static char ebuf[40];
117
if (result >= ISC_R_SUCCESS && result < ISC_R_NRESULTS)
118
return text [result];
119
sprintf(ebuf, "unknown error: %d", result);