Move to kernel style SPDX license identifiers
[babeltrace.git] / include / babeltrace2 / func-status.h
... / ...
CommitLineData
1/*
2 * SPDX-License-Identifier: MIT
3 *
4 * Copyright (C) 2010-2019 EfficiOS Inc. and Linux Foundation
5 */
6
7/*
8 * No include guards here: it is safe to include this file multiple
9 * times.
10 */
11
12#ifndef __BT_IN_BABELTRACE_H
13# error "Please include <babeltrace2/babeltrace.h> instead."
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 */
24#ifndef __BT_FUNC_STATUS_OVERFLOW_ERROR
25# define __BT_FUNC_STATUS_OVERFLOW_ERROR -75
26#endif
27
28/* Memory allocation error */
29#ifndef __BT_FUNC_STATUS_MEMORY_ERROR
30# define __BT_FUNC_STATUS_MEMORY_ERROR -12
31#endif
32
33/* User function error */
34#ifndef __BT_FUNC_STATUS_USER_ERROR
35# define __BT_FUNC_STATUS_USER_ERROR -2
36#endif
37
38/* General error */
39#ifndef __BT_FUNC_STATUS_ERROR
40# define __BT_FUNC_STATUS_ERROR -1
41#endif
42
43/* Saul Goodman */
44#ifndef __BT_FUNC_STATUS_OK
45# define __BT_FUNC_STATUS_OK 0
46#endif
47
48/* End of iteration/consumption */
49#ifndef __BT_FUNC_STATUS_END
50# define __BT_FUNC_STATUS_END 1
51#endif
52
53/* Something can't be found */
54#ifndef __BT_FUNC_STATUS_NOT_FOUND
55# define __BT_FUNC_STATUS_NOT_FOUND 2
56#endif
57
58/* Object is interrupted */
59#ifndef __BT_FUNC_STATUS_INTERRUPTED
60# define __BT_FUNC_STATUS_INTERRUPTED 4
61#endif
62
63/* No match found */
64#ifndef __BT_FUNC_STATUS_NO_MATCH
65# define __BT_FUNC_STATUS_NO_MATCH 6
66#endif
67
68/* Try operation again later */
69#ifndef __BT_FUNC_STATUS_AGAIN
70# define __BT_FUNC_STATUS_AGAIN 11
71#endif
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.02408 seconds and 4 git commands to generate.