|
libexplain
1.4.D001
|
#include <libexplain/ac/fcntl.h>#include <libexplain/buffer/open_flags.h>#include <libexplain/parse_bits.h>#include <libexplain/sizeof.h>#include <libexplain/string_buffer.h>Go to the source code of this file.
Defines | |
| #define | O_DIRECT 0 |
| #define | O_DIRECTORY 0 |
| #define | O_NOFOLLOW 0 |
| #define | O_NOATIME 0 |
| #define | O_CLOEXEC 0 |
| #define | O_LARGEFILE 0 |
Functions | |
| void | explain_buffer_open_flags (explain_string_buffer_t *sb, int flags) |
| int | explain_parse_open_flags_or_die (const char *text, const char *caption) |
Variables | |
| static const explain_parse_bits_table_t | table [] |
| #define O_CLOEXEC 0 |
Definition at line 40 of file open_flags.c.
| #define O_DIRECT 0 |
Definition at line 28 of file open_flags.c.
| #define O_DIRECTORY 0 |
Definition at line 31 of file open_flags.c.
| #define O_LARGEFILE 0 |
Definition at line 51 of file open_flags.c.
| #define O_NOATIME 0 |
Definition at line 37 of file open_flags.c.
| #define O_NOFOLLOW 0 |
Definition at line 34 of file open_flags.c.
| void explain_buffer_open_flags | ( | struct explain_string_buffer_t * | sb, |
| int | flags | ||
| ) |
The explain_buffer_open_flags function may be used to decode the flags argument to the open(2) system call into a humnan readable string, which is one representation of how it would be written by a coder.
| sb | where to put the constructed text. This makes it thread safe, given a suitabley safe buffer. |
| flags | the flags argument passed to the open(2) system call, second argument |
Definition at line 158 of file open_flags.c.
| int explain_parse_open_flags_or_die | ( | const char * | text, |
| const char * | caption | ||
| ) |
The explain_pare_open_flags_or_die function may be used to parse a strings containing a symbolic representation of open() flags, turning it into a open flags value.
| text | The text to be parsed to extract an open flags value. |
| caption | additional text to add to start of error message |
Definition at line 220 of file open_flags.c.
const explain_parse_bits_table_t table[] [static] |
Definition at line 55 of file open_flags.c.
1.7.6.1