aboutsummaryrefslogtreecommitdiffstats
path: root/src/fifo_buffer.h
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/fifo_buffer.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/fifo_buffer.h b/src/fifo_buffer.h
index 661dfd57e..114feec4c 100644
--- a/src/fifo_buffer.h
+++ b/src/fifo_buffer.h
@@ -63,6 +63,19 @@ void
fifo_buffer_free(struct fifo_buffer *buffer);
/**
+ * Return the capacity of the buffer, i.e. the size that was passed to
+ * fifo_buffer_new().
+ */
+size_t
+fifo_buffer_capacity(const struct fifo_buffer *buffer);
+
+/**
+ * Return the number of bytes currently stored in the buffer.
+ */
+size_t
+fifo_buffer_available(const struct fifo_buffer *buffer);
+
+/**
* Clears all data currently in this #fifo_buffer object. This does
* not overwrite the actuall buffer; it just resets the internal
* pointers.