--- a/ucx/buffer.c Mon Jan 22 17:27:47 2024 +0100 +++ b/ucx/buffer.c Sat Jan 27 17:50:19 2024 +0100 @@ -135,6 +135,11 @@ buffer->pos = 0; } +void cxBufferReset(CxBuffer *buffer) { + buffer->size = 0; + buffer->pos = 0; +} + int cxBufferEof(CxBuffer const *buffer) { return buffer->pos >= buffer->size; }