2001-04-24 13:02:58 +00:00
|
|
|
/**
|
|
|
|
* \defgroup Error Error handling
|
|
|
|
* Error handling
|
|
|
|
* \{
|
1998-08-13 15:42:56 +00:00
|
|
|
*/
|
|
|
|
|
|
|
|
#define SND_ERROR_BEGIN 500000
|
1999-07-22 10:49:39 +00:00
|
|
|
#define SND_ERROR_INCOMPATIBLE_VERSION (SND_ERROR_BEGIN+0)
|
1998-08-13 15:42:56 +00:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2000-08-06 12:23:28 +00:00
|
|
|
const char *snd_strerror(int errnum);
|
1998-08-13 15:42:56 +00:00
|
|
|
|
2001-03-29 09:44:29 +00:00
|
|
|
/**
|
|
|
|
* \brief Error handler
|
|
|
|
* \param file File name
|
|
|
|
* \param line Line number
|
|
|
|
* \param function Function name
|
|
|
|
* \param err errno value (or 0 if not relevant)
|
|
|
|
* \param fmt printf(3) format
|
|
|
|
* \param ... printf(3) arguments
|
|
|
|
*/
|
2001-05-22 09:19:43 +00:00
|
|
|
typedef void (snd_lib_error_handler_t)(const char *file, int line, const char *function, int err, const char *fmt, ...) /* __attribute__ ((format (printf, 5, 6))) */;
|
2000-11-25 16:36:18 +00:00
|
|
|
extern snd_lib_error_handler_t *snd_lib_error;
|
|
|
|
extern int snd_lib_error_set_handler(snd_lib_error_handler_t *handler);
|
|
|
|
|
1998-08-13 15:42:56 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2001-04-24 13:02:58 +00:00
|
|
|
/** \} */
|
|
|
|
|