Commit | Line | Data |
---|---|---|
d24d5663 | 1 | /* |
4fa90f32 PP |
2 | * No include guards here: it is safe to include this file multiple |
3 | * times. | |
d24d5663 PP |
4 | */ |
5 | ||
6 | /* | |
bbb7b5f0 | 7 | * Copyright (c) 2010-2019 EfficiOS Inc. and Linux Foundation |
d24d5663 PP |
8 | * |
9 | * Permission is hereby granted, free of charge, to any person obtaining a copy | |
10 | * of this software and associated documentation files (the "Software"), to deal | |
11 | * in the Software without restriction, including without limitation the rights | |
12 | * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
13 | * copies of the Software, and to permit persons to whom the Software is | |
14 | * furnished to do so, subject to the following conditions: | |
15 | * | |
16 | * The above copyright notice and this permission notice shall be included in | |
17 | * all copies or substantial portions of the Software. | |
18 | * | |
19 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
20 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
21 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | |
22 | * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | |
23 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | |
24 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | |
25 | * SOFTWARE. | |
26 | */ | |
27 | ||
4fa90f32 PP |
28 | #ifndef __BT_IN_BABELTRACE_H |
29 | # error "Please include <babeltrace2/babeltrace.h> instead." | |
d24d5663 PP |
30 | #endif |
31 | ||
32 | /* | |
33 | * This is NOT part of the API. | |
34 | * | |
35 | * Do NOT use a `__BT_FUNC_STATUS_*` value in user code: this inhibits | |
36 | * precious type checking. | |
37 | */ | |
38 | ||
39 | /* Value is too large for the given data type */ | |
520cdc82 PP |
40 | #ifndef __BT_FUNC_STATUS_OVERFLOW_ERROR |
41 | # define __BT_FUNC_STATUS_OVERFLOW_ERROR -75 | |
4fa90f32 | 42 | #endif |
d24d5663 | 43 | |
d24d5663 PP |
44 | |
45 | /* Memory allocation error */ | |
4fa90f32 PP |
46 | #ifndef __BT_FUNC_STATUS_MEMORY_ERROR |
47 | # define __BT_FUNC_STATUS_MEMORY_ERROR -12 | |
48 | #endif | |
d24d5663 | 49 | |
27c61ce8 PP |
50 | /* User function error */ |
51 | #ifndef __BT_FUNC_STATUS_USER_ERROR | |
52 | # define __BT_FUNC_STATUS_USER_ERROR -2 | |
53 | #endif | |
54 | ||
d24d5663 | 55 | /* General error */ |
4fa90f32 PP |
56 | #ifndef __BT_FUNC_STATUS_ERROR |
57 | # define __BT_FUNC_STATUS_ERROR -1 | |
58 | #endif | |
d24d5663 PP |
59 | |
60 | /* Saul Goodman */ | |
4fa90f32 PP |
61 | #ifndef __BT_FUNC_STATUS_OK |
62 | # define __BT_FUNC_STATUS_OK 0 | |
63 | #endif | |
d24d5663 PP |
64 | |
65 | /* End of iteration/consumption */ | |
4fa90f32 PP |
66 | #ifndef __BT_FUNC_STATUS_END |
67 | # define __BT_FUNC_STATUS_END 1 | |
68 | #endif | |
d24d5663 PP |
69 | |
70 | /* Something can't be found */ | |
4fa90f32 PP |
71 | #ifndef __BT_FUNC_STATUS_NOT_FOUND |
72 | # define __BT_FUNC_STATUS_NOT_FOUND 2 | |
73 | #endif | |
d24d5663 | 74 | |
9b4f9b42 PP |
75 | /* Object is interrupted */ |
76 | #ifndef __BT_FUNC_STATUS_INTERRUPTED | |
77 | # define __BT_FUNC_STATUS_INTERRUPTED 4 | |
78 | #endif | |
79 | ||
00c988c9 PP |
80 | /* No match found */ |
81 | #ifndef __BT_FUNC_STATUS_NO_MATCH | |
82 | # define __BT_FUNC_STATUS_NO_MATCH 6 | |
83 | #endif | |
84 | ||
d24d5663 | 85 | /* Try operation again later */ |
4fa90f32 PP |
86 | #ifndef __BT_FUNC_STATUS_AGAIN |
87 | # define __BT_FUNC_STATUS_AGAIN 11 | |
88 | #endif | |
76b6c2f7 SM |
89 | |
90 | /* Unknown query object */ | |
91 | #ifndef __BT_FUNC_STATUS_UNKNOWN_OBJECT | |
92 | # define __BT_FUNC_STATUS_UNKNOWN_OBJECT 42 | |
93 | #endif |