aboutsummaryrefslogtreecommitdiffstats
path: root/src/outputBuffer.c
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/outputBuffer.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/outputBuffer.c b/src/outputBuffer.c
index 48e9598f6..525f4af24 100644
--- a/src/outputBuffer.c
+++ b/src/outputBuffer.c
@@ -56,6 +56,16 @@ int outputBufferEmpty(const OutputBuffer * cb)
return cb->begin == cb->end;
}
+void outputBufferShift(OutputBuffer * cb)
+{
+ assert(cb->begin != cb->end);
+ assert(cb->begin < buffered_chunks);
+
+ ++cb->begin;
+ if (cb->begin >= buffered_chunks)
+ cb->begin = 0;
+}
+
unsigned int outputBufferRelative(const OutputBuffer * cb, unsigned i)
{
if (i >= cb->begin)