diff options
Diffstat (limited to 'src/shared/container/ring.h')
-rw-r--r-- | src/shared/container/ring.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/shared/container/ring.h b/src/shared/container/ring.h index 219f4fb..bc978ce 100644 --- a/src/shared/container/ring.h +++ b/src/shared/container/ring.h @@ -14,3 +14,7 @@ void ring_put(ring_t*, void*, size_t); void ring_put1b(ring_t*, uint8_t); size_t ring_get(ring_t*, void*, size_t); + +/** Consumes up to `len` bytes, and returns a pointer to the buffer where it's stored. + * Not thread-safe. */ +void* ring_contig(ring_t*, size_t *len); |