libexplain  1.4.D001
Functions | Variables
libexplain/buffer/waitpid_options.c File Reference
#include <libexplain/ac/sys/wait.h>
#include <libexplain/buffer/waitpid_options.h>
#include <libexplain/parse_bits.h>
#include <libexplain/sizeof.h>
#include <libexplain/string_buffer.h>

Go to the source code of this file.

Functions

void explain_buffer_waitpid_options (explain_string_buffer_t *sb, int options)
int explain_parse_waitpid_options_or_die (const char *text, const char *caption)

Variables

static const
explain_parse_bits_table_t 
table []

Function Documentation

void explain_buffer_waitpid_options ( struct explain_string_buffer_t sb,
int  options 
)

The explain_buffer_waitpid_options function may be used to decode and print waitpid(2) options.

Parameters:
sbThe string buffer to print into
optionsThe options to be decoded

Definition at line 37 of file waitpid_options.c.

int explain_parse_waitpid_options_or_die ( const char *  text,
const char *  caption 
)

The explain_parse_waitpid_options function is used to parse text containing waitpid options into a numeric value.

Parameters:
textThe string to be parsed
captionadditional text to be added to theh start of error messages
Returns:
the flags value

Definition at line 44 of file waitpid_options.c.


Variable Documentation

Initial value:
{
    { "WNOHANG", WNOHANG },
    { "WUNTRACED", WUNTRACED },
    { "WCONTINUED", WCONTINUED },
}

Definition at line 28 of file waitpid_options.c.