man rbuf_insert (Fonctions bibliothèques) - insert a value into an rbuf

NAME

rbuf_insert_rbuf, rbuf_insert_data - insert a value into an rbuf

SYNOPSIS

#include <roy.h>

void rbuf_insert_str (RBuf *buf, unsigned int pos, const char *val);

void rbuf_insert_rbuf (RBuf *buf, unsigned int pos, const RBuf *val);

void rbuf_insert_data (RBuf *buf, unsigned int pos, const char *val, unsigned int len);

DESCRIPTION

These calls allow the programmer to insert data into the middle of buf. Any existing data located after the insert position pos in buf will be moved down buf's buffer the length of the inserted data. The buffer will be grown if needed.

If pos is zero (0) these calls to act like rbuf_prepend(3). If pos is greater then buf's length then these calls pretend that the buffer was filled with '\0's up until pos.

RETURN VALUE

These calls return no value.

ERRORS

If pos is greater than the length of the buffer, the call will return without modifying the contents of the buffer.

FUNCTION

These calls are implemented using functions.

SEE ALSO