Home | History | Annotate | Download | only in src

Lines Matching full:buf

48 buffer_t *buffer_new_ref(const buffer_t *buf) {
49 assert(buf != NULL);
50 return buffer_new_slice(buf, buf->length);
53 buffer_t *buffer_new_slice(const buffer_t *buf, size_t slice_size) {
54 assert(buf != NULL);
56 assert(slice_size <= buf->length);
60 ret->root = buf->root;
64 ++buf->root->refcount;
84 void *buffer_ptr(const buffer_t *buf) {
85 assert(buf != NULL);
86 return buf->root->data + buf->root->length - buf->length;
89 size_t buffer_length(const buffer_t *buf) {
90 assert(buf != NULL);
91 return buf->length;