Paraslash Audio Streaming | |
About News Download Documentation Development |
List of error codes and messages. More...
Macros | |
#define | SYSTEM_ERROR_BIT 30 |
para_error More... | |
#define | OSL_ERROR_BIT 29 |
Like SYSTEM_ERROR_BIT, but for errors from the osl library. More... | |
#define | LLS_ERROR_BIT 28 |
Like SYSTEM_ERROR_BIT, but for errors from the lopsub library. More... | |
#define | IS_SYSTEM_ERROR(num) (!!((num) & (1 << SYSTEM_ERROR_BIT))) |
Check whether the system error bit is set. More... | |
#define | IS_OSL_ERROR(num) (!!((num) & (1 << OSL_ERROR_BIT))) |
Check whether the osl error bit is set. More... | |
#define | IS_LLS_ERROR(num) (!!((num) & (1 << LLS_ERROR_BIT))) |
Check whether the lopsub error bit is set. More... | |
#define | ERRNO_TO_PARA_ERROR(num) ((num) | (1 << SYSTEM_ERROR_BIT)) |
Set the system error bit for the given number. More... | |
#define | OSL_ERRNO_TO_PARA_ERROR(num) ((num) | (1 << OSL_ERROR_BIT)) |
Set the osl error bit for the given number. More... | |
#define | LLS_ERRNO_TO_PARA_ERROR(num) ((num) | (1 << LLS_ERROR_BIT)) |
Set the lopsub error bit for the error code. More... | |
Functions | |
_static_inline_ const char * | para_strerror (int num) |
Paraslash's version of strerror(3). More... | |
_static_inline_ int | osl (int ret) |
Wrapper for osl library calls. More... | |
_static_inline_ int | lls (int ret) |
Wrapper for lopsub library calls. More... | |
List of error codes and messages.
#define SYSTEM_ERROR_BIT 30 |
para_error
This bit indicates whether a number is considered a system error number If yes, the system errno is just the result of clearing this bit from the given number.
#define OSL_ERROR_BIT 29 |
Like SYSTEM_ERROR_BIT, but for errors from the osl library.
#define LLS_ERROR_BIT 28 |
Like SYSTEM_ERROR_BIT, but for errors from the lopsub library.
#define IS_SYSTEM_ERROR | ( | num | ) | (!!((num) & (1 << SYSTEM_ERROR_BIT))) |
Check whether the system error bit is set.
#define IS_OSL_ERROR | ( | num | ) | (!!((num) & (1 << OSL_ERROR_BIT))) |
Check whether the osl error bit is set.
#define IS_LLS_ERROR | ( | num | ) | (!!((num) & (1 << LLS_ERROR_BIT))) |
Check whether the lopsub error bit is set.
#define ERRNO_TO_PARA_ERROR | ( | num | ) | ((num) | (1 << SYSTEM_ERROR_BIT)) |
Set the system error bit for the given number.
#define OSL_ERRNO_TO_PARA_ERROR | ( | num | ) | ((num) | (1 << OSL_ERROR_BIT)) |
Set the osl error bit for the given number.
#define LLS_ERRNO_TO_PARA_ERROR | ( | num | ) | ((num) | (1 << LLS_ERROR_BIT)) |
Set the lopsub error bit for the error code.
_static_inline_ const char* para_strerror | ( | int | num | ) |
Paraslash's version of strerror(3).
num | The error number. |
References IS_OSL_ERROR, LLS_ERROR_BIT, OSL_ERROR_BIT, and SYSTEM_ERROR_BIT.
Referenced by afs_error(), check_receiver_arg(), generic_com_on(), send_strerror(), task_notify(), and task_reap().
_static_inline_ int osl | ( | int | ret | ) |
Wrapper for osl library calls.
ret | The return value of an osl library function. |
This should be used for all calls to osl functions that return an osl error code. It changes the return value appropriately so that it can be used for printing the correct error message with para_strerror().
References OSL_ERRNO_TO_PARA_ERROR.
Referenced by aft_get_row_of_path(), audio_file_loop(), for_each_matching_row(), get_afhi_of_row(), get_attribute_bitnum_by_name(), get_audio_file_path_of_row(), mood_check_callback(), playlist_check_callback(), score_get_best(), score_loop(), score_open(), and score_update().
_static_inline_ int lls | ( | int | ret | ) |
Wrapper for lopsub library calls.
ret | See osl(). |
References LLS_ERRNO_TO_PARA_ERROR.
Referenced by check_receiver_arg(), filter_setup(), and main().