This is the latest (main) BeagleBoard documentation. If you are looking for stable releases, use the drop-down menu on the bottom-left and select the desired version.

Function rc_ringbuf_empty

Function Documentation

rc_ringbuf_t rc_ringbuf_empty(void)

Returns an rc_ringbuf_t struct which is completely zero’d out with no memory allocated for it.

This is essential for declaring new ring buffers since structs declared inside of functions are not necessarily zero’d out which can cause the struct to contain problematic contents leading to segfaults. New ring buffers should be initialized with this before calling rc_ringbuf_alloc.

Returns

empty and ready-to-allocate rc_ringbuf_t