14192
|
1 #include "zephyr_err.h"
|
|
2
|
|
3 #ifdef __STDC__
|
|
4 #define NOARGS void
|
|
5 #else
|
|
6 #define NOARGS
|
|
7 #define const
|
|
8 #endif
|
|
9
|
|
10 static const char * const text[] = {
|
|
11 "Packet too long or buffer too small",
|
|
12 "Notice header too large",
|
|
13 "Illegal value in notice",
|
|
14 "Can't get host manager port",
|
|
15 "Can't assign port",
|
|
16 "Bad packet format",
|
|
17 "Incompatible version numbers",
|
|
18 "No port opened",
|
|
19 "No notices match criteria",
|
|
20 "Input queue too long",
|
|
21 "Hostmanager not responding",
|
|
22 "Internal error",
|
|
23 "No previous call to ZLocateUser",
|
|
24 "No more locations available",
|
|
25 "Field too long for buffer",
|
|
26 "Improperly formatted field",
|
|
27 "SERVNAK received",
|
|
28 "Server could not verify authentication",
|
|
29 "Not logged-in",
|
|
30 "No previous call to ZRetrieveSubscriptions",
|
|
31 "No more subscriptions available",
|
|
32 "Too many subscriptions to transmit",
|
|
33 "End of file detected during read",
|
|
34 0
|
|
35 };
|
|
36
|
|
37 struct error_table {
|
|
38 char const * const * msgs;
|
|
39 long base;
|
|
40 int n_msgs;
|
|
41 };
|
|
42 struct et_list {
|
|
43 struct et_list *next;
|
|
44 const struct error_table * table;
|
|
45 };
|
|
46 extern struct et_list *_et_list;
|
|
47
|
|
48 static const struct error_table et = { text, -772103680L, 23 };
|
|
49
|
|
50 static struct et_list link = { 0, 0 };
|
|
51
|
|
52 void initialize_zeph_error_table (NOARGS) {
|
|
53 if (!link.table) {
|
|
54 link.next = _et_list;
|
|
55 link.table = &et;
|
|
56 _et_list = &link;
|
|
57 }
|
|
58 }
|