summaryrefslogtreecommitdiff
path: root/src/err-codes.h.in
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2019-12-13 09:38:34 +0100
committerWerner Koch <wk@gnupg.org>2019-12-13 09:40:22 +0100
commit308574372055662c76d27f1681b182afddce9166 (patch)
tree23b82ca2b77d0c1c3b386e1095a90027d42f16d6 /src/err-codes.h.in
parent9280ce104efd301802b546a8be6c3937b8768442 (diff)
downloadlibgpg-error-308574372055662c76d27f1681b182afddce9166.tar.gz
New error codes for SQLite
* src/err-codes.h.in: Add GPG_ERR_SQL_ codes. * src/gpg-error.h.in (gpg_err_code_from_sqlite): New. Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'src/err-codes.h.in')
-rw-r--r--src/err-codes.h.in42
1 files changed, 41 insertions, 1 deletions
diff --git a/src/err-codes.h.in b/src/err-codes.h.in
index 3178b58..c65775f 100644
--- a/src/err-codes.h.in
+++ b/src/err-codes.h.in
@@ -474,7 +474,47 @@
1038 GPG_ERR_USER_15 User defined error code 15
1039 GPG_ERR_USER_16 User defined error code 16
-# 1040 to 16380 are free to be used.
+# 1040 to 1499 are free to be used.
+
+# 1500 to 1755 are mapped SQLite primary error codes.
+1500 GPG_ERR_SQL_OK SQL success
+1501 GPG_ERR_SQL_ERROR SQL error
+1502 GPG_ERR_SQL_INTERNAL Internal logic error in SQL library
+1503 GPG_ERR_SQL_PERM Access permission denied (SQL)
+1504 GPG_ERR_SQL_ABORT SQL abort was requested
+1505 GPG_ERR_SQL_BUSY SQL database file is locked
+1506 GPG_ERR_SQL_LOCKED An SQL table in the database is locked
+1507 GPG_ERR_SQL_NOMEM SQL library ran out of core
+1508 GPG_ERR_SQL_READONLY Attempt to write a readonly SQL database
+1509 GPG_ERR_SQL_INTERRUPT SQL operation terminated by interrupt
+1510 GPG_ERR_SQL_IOERR I/O error during SQL operation
+1511 GPG_ERR_SQL_CORRUPT SQL database disk image is malformed
+1512 GPG_ERR_SQL_NOTFOUND Unknown opcode in SQL file control
+1513 GPG_ERR_SQL_FULL Insertion failed because SQL database is full
+1514 GPG_ERR_SQL_CANTOPEN Unable to open the SQL database file
+1515 GPG_ERR_SQL_PROTOCOL SQL database lock protocol error
+1516 GPG_ERR_SQL_EMPTY (internal SQL code: empty)
+1517 GPG_ERR_SQL_SCHEMA SQL database schema changed
+1518 GPG_ERR_SQL_TOOBIG String or blob exceeds size limit (SQL)
+1519 GPG_ERR_SQL_CONSTRAINT SQL abort due to constraint violation
+1520 GPG_ERR_SQL_MISMATCH Data type mismatch (SQL)
+1521 GPG_ERR_SQL_MISUSE SQL library used incorrectly
+1522 GPG_ERR_SQL_NOLFS SQL library uses unsupported OS features
+1523 GPG_ERR_SQL_AUTH Authorization denied (SQL)
+1524 GPG_ERR_SQL_FORMAT (unused SQL code: format)
+1525 GPG_ERR_SQL_RANGE SQL bind parameter out of range
+1526 GPG_ERR_SQL_NOTADB File opened that is not an SQL database file
+1527 GPG_ERR_SQL_NOTICE Notifications from SQL logger
+1528 GPG_ERR_SQL_WARNING Warnings from SQL logger
+
+# 1529 to 1599 are reserved for newer SQLite primary error codes.
+
+1600 GPG_ERR_SQL_ROW SQL has another row ready
+1601 GPG_ERR_SQL_DONE SQL has finished executing
+
+# 1602 to 1755 are reserved for newer SQLite primary error codes.
+
+# 1756 to 16380 are free to be used.
16381 GPG_ERR_MISSING_ERRNO System error w/o errno
16382 GPG_ERR_UNKNOWN_ERRNO Unknown system error