summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/mailutils/errno.h17
-rw-r--r--mailbox/muerrno.c19
2 files changed, 36 insertions, 0 deletions
diff --git a/include/mailutils/errno.h b/include/mailutils/errno.h
index 7d6e6a4fe..641543c2d 100644
--- a/include/mailutils/errno.h
+++ b/include/mailutils/errno.h
@@ -97,6 +97,23 @@ extern "C" {
97 /* Requested item not found */ 97 /* Requested item not found */
98#define MU_ERR_BUFSPACE (MU_ERR_BASE + 40) 98#define MU_ERR_BUFSPACE (MU_ERR_BASE + 40)
99 /* Not enough buffer space */ 99 /* Not enough buffer space */
100
101#define MU_ERR_SQL (MU_ERR_BASE + 41)
102 /* SQL error */
103#define MU_ERR_DB_ALREADY_CONNECTED (MU_ERR_BASE + 42)
104 /* Already connected to the database */
105#define MU_ERR_DB_NOT_CONNECTED (MU_ERR_BASE + 43)
106 /* Not connected to the database */
107#define MU_ERR_RESULT_NOT_RELEASED (MU_ERR_BASE + 44)
108 /* Result of the previous query is not released */
109#define MU_ERR_NO_QUERY (MU_ERR_BASE + 45)
110 /* No query was executed */
111#define MU_ERR_BAD_COLUMN (MU_ERR_BASE + 46)
112 /* Bad column address */
113#define MU_ERR_NO_RESULT (MU_ERR_BASE + 47)
114 /* No result from the previous query available */
115#define MU_ERR_NO_INTERFACE (MU_ERR_BASE + 48)
116 /* No such interface */
100 117
101const char *mu_errname __P((int e)); 118const char *mu_errname __P((int e));
102const char *mu_strerror __P((int e)); 119const char *mu_strerror __P((int e));
diff --git a/mailbox/muerrno.c b/mailbox/muerrno.c
index d5154a842..75e31120e 100644
--- a/mailbox/muerrno.c
+++ b/mailbox/muerrno.c
@@ -99,6 +99,15 @@ mu_errname (int e)
99 EN(MU_ERR_PARSE); 99 EN(MU_ERR_PARSE);
100 EN(MU_ERR_NOENT); 100 EN(MU_ERR_NOENT);
101 EN(MU_ERR_BUFSPACE); 101 EN(MU_ERR_BUFSPACE);
102
103 EN(MU_ERR_SQL);
104 EN(MU_ERR_DB_ALREADY_CONNECTED);
105 EN(MU_ERR_DB_NOT_CONNECTED);
106 EN(MU_ERR_RESULT_NOT_RELEASED);
107 EN(MU_ERR_NO_QUERY);
108 EN(MU_ERR_BAD_COLUMN);
109 EN(MU_ERR_NO_RESULT);
110 EN(MU_ERR_NO_INTERFACE);
102 } 111 }
103 112
104 snprintf (buf, sizeof buf, _("Error %d"), e); 113 snprintf (buf, sizeof buf, _("Error %d"), e);
@@ -167,6 +176,16 @@ mu_strerror (int e)
167 ES(MU_ERR_PARSE, _("Parse error")); 176 ES(MU_ERR_PARSE, _("Parse error"));
168 ES(MU_ERR_NOENT, _("Requested item not found")); 177 ES(MU_ERR_NOENT, _("Requested item not found"));
169 ES(MU_ERR_BUFSPACE, _("Not enough buffer space")); 178 ES(MU_ERR_BUFSPACE, _("Not enough buffer space"));
179
180 ES(MU_ERR_SQL, _("SQL error"));
181 ES(MU_ERR_DB_ALREADY_CONNECTED, _("Already connected to the database"));
182 ES(MU_ERR_DB_NOT_CONNECTED, _("Not connected to the database"));
183 ES(MU_ERR_RESULT_NOT_RELEASED, _("Result of the previous query is not released"));
184 ES(MU_ERR_NO_QUERY, _("No query was executed"));
185 ES(MU_ERR_BAD_COLUMN, _("Bad column address"));
186 ES(MU_ERR_NO_RESULT, _("No result from the previous query available"));
187
188 ES(MU_ERR_NO_INTERFACE, _("No such interface"));
170 } 189 }
171 190
172 return msg ? msg : strerror (e); 191 return msg ? msg : strerror (e);

Return to:

Send suggestions and report system problems to the System administrator.