-
Notifications
You must be signed in to change notification settings - Fork 11
/
db_error.h
58 lines (55 loc) · 1.39 KB
/
db_error.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#pragma once
#define db_abort(expr, msg, val) (fprintf(stderr, "db_abort: line:%d file:%s\nexpr:(%s) is false: %s\n", __LINE__, __FILE__, #expr, msg), abort(), val)
typedef enum {
DB_OK = 0,
DB_START = 1000,
DB_ERROR_duplicate_suffix,
DB_ERROR_outofmemory,
DB_ERROR_handleclosed,
DB_ERROR_createdatabase,
DB_ERROR_createindex,
DB_ERROR_badhandle,
DB_ERROR_badrecid,
DB_ERROR_badobjslot,
DB_ERROR_notbasever,
DB_ERROR_recorddeleted,
DB_ERROR_recordnotvisible,
DB_ERROR_notcurrentversion,
DB_ERROR_cursornotpositioned,
DB_ERROR_invaliddeleterecord,
DB_ERROR_cursorbasekeyerror,
DB_ERROR_cursoroverflow,
DB_ERROR_cursorop,
DB_ERROR_writeconflict,
DB_ERROR_duplicatekey,
DB_ERROR_keylength,
DB_ERROR_keynotfound,
DB_ERROR_badtxnstep,
DB_ERROR_rollbackidxkey,
DB_ERROR_arena_already_closed,
DB_ERROR_arenadropped,
DB_ERROR_deletekey,
DB_ERROR_indextype,
DB_ERROR_indexnode,
DB_ERROR_unique_key_constraint,
DB_CURSOR_eof,
DB_CURSOR_notfound,
DB_CURSOR_notpositioned,
DB_CURSOR_nothandle,
DB_ITERATOR_eof,
DB_ITERATOR_notfound,
DB_ITERATOR_nothandle,
DB_BTREE_needssplit,
DB_BTREE_error,
DB_ARTREE_error,
DB_ITER_eof,
DB_ERROR_pageisgarbage,
DB_ERROR_txn_being_committed,
DB_ERROR_txn_not_serializable,
DB_ERROR_key_constraint_violation,
DB_ERROR_no_visible_version,
DB_ERROR_not_raw_document,
MVCC_WriteConflict,
MVCC_outofmemory,
MVCC_NoTimestampSlots,
} DbStatus;