NAME

catbuf_overwrite - static write operation on a buffer

SYNOPSIS

#include <cat.h>

int catbuf_overwrite(cat_buffer *b, int pos, int length, const void *data)

DESCRIPTION

The catbuf_overwrite() function performs a write operation on a buffer, within the buffer's size boundaries and without changing the index.

catbuf_overwrite() overwrites data in a buffer, starting at pos, and extending the buffer length by length, a number of bytes. The buffer length is not extended outside the current size of the buffer. The index is unaffected.

catbuf_copy() performs the corresponding static read operation.

RETURN VALUES

Returns 0 if successful, or a negative code on error.

SEE ALSO

cat, catbuf, catbuf_copy