imap_err.c revision da5a6b4317fe8939cc98a18c30668fa323641fe9
1/*
2 * imap_err.c:
3 * This file is automatically generated; please do not edit it.
4 */
5
6#include <stdlib.h>
7
8#define N_(a) a
9
10static const char * const text[] = {
11	N_(   "System I/O error"),
12	N_(   "Permission denied"),
13	N_(   "Over quota"),
14	N_(   "Too many user flags in mailbox"),
15	N_(   "Mailbox has an invalid format"),
16	N_(   "Operation is not supported on mailbox"),
17	N_(   "Mailbox does not exist"),
18	N_(   "Mailbox already exists"),
19	N_(   "Invalid mailbox name"),
20	N_(   "Mailbox is locked by POP server"),
21	N_(   "Unknown/invalid partition"),
22	N_(   "Invalid identifier"),
23	N_(   "Message contains NUL characters"),
24	N_(   "Message contains bare newlines"),
25	N_(   "Message contains non-ASCII characters in headers"),
26	N_(   "Message contains invalid header"),
27	N_(   "Message has no header/body separator"),
28	N_(   "Quota root does not exist"),
29	N_(   "Unrecognized character set"),
30	N_(   "Invalid user"),
31	N_(   "Login incorrect"),
32	N_(   "Anonymous login is not permitted"),
33	N_(   "Unsupported quota resource"),
34	N_(   "Mailbox is over quota"),
35	N_(   "Mailbox is at %d%% of quota"),
36	N_(   "Message %d no longer exists"),
37	N_(   "Unable to checkpoint \\Seen state"),
38	N_(   "Unable to preserve \\Seen state"),
39	N_(   "LOGOUT received"),
40	N_(   "Completed"),
41    0
42};
43
44struct error_table {
45    char const * const * msgs;
46    long base;
47    int n_msgs;
48};
49struct et_list {
50    struct et_list *next;
51    const struct error_table * table;
52};
53extern struct et_list *_et_list;
54
55const struct error_table et_imap_error_table = { text, -1904809472L, 30 };
56
57static struct et_list link = { 0, 0 };
58
59void initialize_imap_error_table_r(struct et_list **list);
60void initialize_imap_error_table(void);
61
62void initialize_imap_error_table(void) {
63    initialize_imap_error_table_r(&_et_list);
64}
65
66/* For Heimdal compatibility */
67void initialize_imap_error_table_r(struct et_list **list)
68{
69    struct et_list *et, **end;
70
71    for (end = list, et = *list; et; end = &et->next, et = et->next)
72        if (et->table->msgs == text)
73            return;
74    et = malloc(sizeof(struct et_list));
75    if (et == 0) {
76        if (!link.table)
77            et = &link;
78        else
79            return;
80    }
81    et->table = &et_imap_error_table;
82    et->next = 0;
83    *end = et;
84}
85