38#define AS_ERROR_MESSAGE_MAX_SIZE 1024
43#define AS_ERROR_MESSAGE_MAX_LEN (AS_ERROR_MESSAGE_MAX_SIZE - 1)
93typedef struct as_error_s {
138#define as_error_update(__err, __code, __fmt, ...) \
139 as_error_setallv( __err, __code, __func__, __FILE__, __LINE__, __fmt, ##__VA_ARGS__ );
146#define as_error_set_message(__err, __code, __msg) \
147 as_error_setall( __err, __code, __msg, __func__, __FILE__, __LINE__ );
249 err->
in_doubt = (!is_read && (command_sent_counter > 1 || (command_sent_counter == 1 &&
#define AS_ERROR_MESSAGE_MAX_LEN
#define AS_ERROR_MESSAGE_MAX_SIZE
AS_EXTERN bool as_strncpy(char *trg, const char *src, int size)
static void as_error_append(as_error *err, const char *str)
char message[AS_ERROR_MESSAGE_MAX_SIZE]
static as_status as_error_setall(as_error *err, as_status code, const char *message, const char *func, const char *file, uint32_t line)
static as_status as_error_setallv(as_error *err, as_status code, const char *func, const char *file, uint32_t line, const char *fmt,...)
AS_EXTERN char * as_error_string(as_status status)
static void as_error_copy(as_error *trg, const as_error *src)
static as_status as_error_reset(as_error *err)
static as_error * as_error_init(as_error *err)
static void as_error_set_in_doubt(as_error *err, bool is_read, uint32_t command_sent_counter)