Errors
Names error types from the kernel and the userspace IPC contracts.
Types
| Type |
Definition |
Description |
Err |
int32_t |
Generic error code type. Non-positive error code. Never positive Check zuzu/err.h for error codes. |
Constants
| Name |
Value |
Description |
ZUZU_OK |
0 |
No error has occurred, the operation was successful. |
ERR_NOPERM |
(-1) |
Caller does not have the necessary permission for this operation. |
ERR_NOENT |
(-2) |
The requested entry in a list, table etc. could not be found |
ERR_BUSY |
(-3) |
The requested resource is being used, is referenced, or currently unavailable. Try again or ensure no other party is using it. |
ERR_NOMEM |
(-4) |
Memory for this operation could not be allocated. |
ERR_BADTYPE |
(-5) |
Type-check failed, this handle is not the required type. |
ERR_BADARG |
(-6) |
Argument is NULL or otherwise unusable. |
ERR_NOSYS |
(-7) |
This operation is not supported by the system. |
ERR_BADPTR |
(-8) |
The pointer does not point to the required data, is NULL, or unfit. |
ERR_DEAD |
(-9) |
Object owner has died. |
ERR_TIMEOUT |
(-10) |
Wait timed out. |
ERR_OVERFLOW |
(-11) |
The transport request will not fit into the destination. |
ERR_BADHANDLE |
(-12) |
This handle is not a valid handle for this operation. |
ERR_BUFFULL |
(-100) |
Buffer full, cannot receive anymore. |
ERR_BUFEMPTY |
(-101) |
Buffer empty, cannot send anymore. |
ERR_SYSDOWN |
(-102) |
System is not up (yet). |
ERR_NOTCONN |
(-103) |
System is not connected. |
ERR_DUPLICATE |
(-104) |
This is a duplicate, and having duplicates in this operation would be invalid. |
ERR_MALFORMED |
(-105) |
Format is incorrect. |
ERR_IO |
(-106) |
Input/output has failed. |
ERR_OUTDATED |
(-107) |
This request is outdated, or operation cannot continue due to an issue with outdated code/data. |
ERR_CONNRESET |
(-108) |
TCP connection reset. |
ERR_CONNREFUSED |
(-109) |
TCP connection refused. |
Enumerations
KilledReason
Task kill reason.
| Name |
Value |
Description |
KILLED_BY_PARENT |
0 |
Parent destroyed the task object. |
KILLED_FAULT_DATA |
1 |
The task caused a data abort. |
KILLED_FAULT_PREFETCH |
2 |
The task caused a prefetch abort. |
KILLED_FAULT_UNDEF |
3 |
The task executed an undefined instruction. |
KILLED_FAULT_ALIGN |
4 |
The task accessed unaligned memory. |
KILLED_OOM |
5 |
The task was victim to an OOM service. |
Functions
StrToError
const char * StrToError(Err errcode);
Converts an error code into a short explanatory string, or ERR -XXX if the error is unknown.
| Parameter |
Direction |
Description |
errcode |
in |
Numeric error code. |
Returns: Explanatory string.