Hiemal Internals

Buffer Implementation

struct _buffer

buffer struct

Public Members

void *buf

pointer to raw buffer

unsigned int buf_len_bytes

number of bytes allocated for buffer

void *read_ptr

read pointer

void *write_ptr

write pointer

buffer_type_t type

buffer type (LINEAR or RING)

buffer_state_t state

buffer state (EMPTY, FULL or NORMAL)

bool in_use

is the buffer currently being read from/written to?

bool ext_buf

was the buffer initialized externally (i.e. not with buffer_init())?