|
typedef void(* | snd_lib_error_handler_t) (const char *file, int line, const char *function, int err, const char *fmt,...) |
| Error handler callback. More...
|
|
Error handling macros and functions.
◆ SND_ERROR_ALISP_NIL
Lisp encountered an error during acall.
◆ SND_ERROR_BEGIN
#define SND_ERROR_BEGIN 500000 |
Lower boundary of sound error codes.
◆ SND_ERROR_INCOMPATIBLE_VERSION
Kernel/library protocols are not compatible.
◆ SNDERR
#define SNDERR |
( |
|
args... | ) |
snd_lib_error(__FILE__, __LINE__, __func__, 0, ##args) |
Shows a sound error message.
◆ SYSERR
#define SYSERR |
( |
|
args... | ) |
snd_lib_error(__FILE__, __LINE__, __func__, errno, ##args) |
Shows a system error message (related to errno
).
◆ snd_lib_error_handler_t
typedef void(* snd_lib_error_handler_t) (const char *file, int line, const char *function, int err, const char *fmt,...) |
Error handler callback.
- Parameters
-
file | Source file name. |
line | Line number. |
function | Function name. |
err | Value of errno , or 0 if not relevant. |
fmt | printf(3) format. |
... | printf(3) arguments. |
A function of this type is called by the ALSA library when an error occurs. This function usually shows the message on the screen, and/or logs it.
◆ snd_lib_error_set_handler()
Sets the error handler.
- Parameters
-
handler | The pointer to the new error handler function. |
This function sets a new error handler, or (if handler
is NULL
) the default one which prints the error messages to stderr
.
◆ snd_strerror()
const char * snd_strerror |
( |
int |
errnum | ) |
|
◆ snd_lib_error [1/2]
Pointer to the error handler function. For internal use only.
◆ snd_lib_error [2/2]
Pointer to the error handler function. For internal use only.