libexplain
1.4.D001
|
#include <libexplain/ac/stddef.h>
Go to the source code of this file.
Data Structures | |
struct | explain_errno_info_t |
Typedefs | |
typedef struct explain_errno_info_t | explain_errno_info_t |
Functions | |
const explain_errno_info_t * | explain_errno_info_by_number (int errnum) |
const explain_errno_info_t * | explain_errno_info_by_name (const char *name) |
const explain_errno_info_t * | explain_errno_info_by_name_fuzzy (const char *name) |
const explain_errno_info_t * | explain_errno_info_by_text (const char *text) |
const explain_errno_info_t * | explain_errno_info_by_text_fuzzy (const char *text) |
const char * | explain_internal_strerror (int n) |
void | explain_internal_strerror_r (int errnum, char *data, size_t data_size) |
typedef struct explain_errno_info_t explain_errno_info_t |
The explain_errno_info_t type describes an errno value, and its (macro) name.
While the tables contains a description string, it is only used if the "internal-strerror=true" option is set. It is principally of use for automated testing, to elimitate differences between Unix implimentations.
Definition at line 34 of file errno_info.h.
const explain_errno_info_t* explain_errno_info_by_name | ( | const char * | name | ) |
const explain_errno_info_t* explain_errno_info_by_name_fuzzy | ( | const char * | name | ) |
The explain_errno_info_by_name_fuzzy function may be used to locate errno information by errno name, using fuzzy matching. (For best results, try the exact match first.)
name | The error name ("ENOENT", etc) |
Definition at line 25 of file by_name_fuzzy.c.
const explain_errno_info_t* explain_errno_info_by_number | ( | int | errnum | ) |
The explain_errno_info_by_number function may be used to locate errno information by errno number.
errnum | The error number |
Definition at line 24 of file by_number.c.
const explain_errno_info_t* explain_errno_info_by_text | ( | const char * | text | ) |
const explain_errno_info_t* explain_errno_info_by_text_fuzzy | ( | const char * | text | ) |
The explain_errno_info_by_text_fuzzy function may be used to locate errno information by errno text, using fuzzy matching. (For best results, try the exact match first.)
text | The error text ("No such file or directory", etc) |
Definition at line 27 of file by_text_fuzzy.c.
const char* explain_internal_strerror | ( | int | n | ) |
The explain_internal_strerror method may be used to obtain a string corresponding to an error number. It honors the explain_option_internal_strerror flag.
Definition at line 27 of file internal_strerror.c.
void explain_internal_strerror_r | ( | int | errnum, |
char * | data, | ||
size_t | data_size | ||
) |
The explain_internal_strerror_r method may be used to obtain a string corresponding to an error number. It honors the explain_option_internal_strerror flag.
errnum | The error number to describe |
data | The array in which to return the result. |
data_size | The maximum size of thereturned string, including the terminating NUL character. |
Definition at line 42 of file internal_strerror.c.