Move to kernel style SPDX license identifiers
[babeltrace.git] / include / babeltrace2 / func-status.h
CommitLineData
d24d5663 1/*
0235b0db
MJ
2 * SPDX-License-Identifier: MIT
3 *
4 * Copyright (C) 2010-2019 EfficiOS Inc. and Linux Foundation
d24d5663
PP
5 */
6
7/*
0235b0db
MJ
8 * No include guards here: it is safe to include this file multiple
9 * times.
d24d5663
PP
10 */
11
4fa90f32
PP
12#ifndef __BT_IN_BABELTRACE_H
13# error "Please include <babeltrace2/babeltrace.h> instead."
d24d5663
PP
14#endif
15
16/*
17 * This is NOT part of the API.
18 *
19 * Do NOT use a `__BT_FUNC_STATUS_*` value in user code: this inhibits
20 * precious type checking.
21 */
22
23/* Value is too large for the given data type */
520cdc82
PP
24#ifndef __BT_FUNC_STATUS_OVERFLOW_ERROR
25# define __BT_FUNC_STATUS_OVERFLOW_ERROR -75
4fa90f32 26#endif
d24d5663 27
d24d5663 28/* Memory allocation error */
4fa90f32
PP
29#ifndef __BT_FUNC_STATUS_MEMORY_ERROR
30# define __BT_FUNC_STATUS_MEMORY_ERROR -12
31#endif
d24d5663 32
27c61ce8
PP
33/* User function error */
34#ifndef __BT_FUNC_STATUS_USER_ERROR
35# define __BT_FUNC_STATUS_USER_ERROR -2
36#endif
37
d24d5663 38/* General error */
4fa90f32
PP
39#ifndef __BT_FUNC_STATUS_ERROR
40# define __BT_FUNC_STATUS_ERROR -1
41#endif
d24d5663
PP
42
43/* Saul Goodman */
4fa90f32
PP
44#ifndef __BT_FUNC_STATUS_OK
45# define __BT_FUNC_STATUS_OK 0
46#endif
d24d5663
PP
47
48/* End of iteration/consumption */
4fa90f32
PP
49#ifndef __BT_FUNC_STATUS_END
50# define __BT_FUNC_STATUS_END 1
51#endif
d24d5663
PP
52
53/* Something can't be found */
4fa90f32
PP
54#ifndef __BT_FUNC_STATUS_NOT_FOUND
55# define __BT_FUNC_STATUS_NOT_FOUND 2
56#endif
d24d5663 57
9b4f9b42
PP
58/* Object is interrupted */
59#ifndef __BT_FUNC_STATUS_INTERRUPTED
60# define __BT_FUNC_STATUS_INTERRUPTED 4
61#endif
62
00c988c9
PP
63/* No match found */
64#ifndef __BT_FUNC_STATUS_NO_MATCH
65# define __BT_FUNC_STATUS_NO_MATCH 6
66#endif
67
d24d5663 68/* Try operation again later */
4fa90f32
PP
69#ifndef __BT_FUNC_STATUS_AGAIN
70# define __BT_FUNC_STATUS_AGAIN 11
71#endif
76b6c2f7
SM
72
73/* Unknown query object */
74#ifndef __BT_FUNC_STATUS_UNKNOWN_OBJECT
75# define __BT_FUNC_STATUS_UNKNOWN_OBJECT 42
76#endif
This page took 0.041017 seconds and 4 git commands to generate.