aboutsummaryrefslogtreecommitdiffstats
path: root/src/outputBuffer.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-04-12 04:18:19 +0000
committerEric Wong <normalperson@yhbt.net>2008-04-12 04:18:19 +0000
commit20c4638a2eb28bd66cd4494b706f113f60a2c0e2 (patch)
tree8de8be5b19586b6cd509de8e510b95c39aac33c2 /src/outputBuffer.c
parente20b71ed63314d68407b5583e67f2617f916a9e4 (diff)
downloadmpd-20c4638a2eb28bd66cd4494b706f113f60a2c0e2.tar.gz
mpd-20c4638a2eb28bd66cd4494b706f113f60a2c0e2.tar.xz
mpd-20c4638a2eb28bd66cd4494b706f113f60a2c0e2.zip
added output_buffer_skip()
First patch without camelCase ;) output_buffer_skip() lets us eliminate advanceOutputBufferTo(), and removes yet another external OutputBuffer struct access. git-svn-id: https://svn.musicpd.org/mpd/trunk@7312 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to 'src/outputBuffer.c')
-rw-r--r--src/outputBuffer.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/outputBuffer.c b/src/outputBuffer.c
index 0d114a1a6..4995fa9a5 100644
--- a/src/outputBuffer.c
+++ b/src/outputBuffer.c
@@ -218,3 +218,9 @@ int sendDataToOutputBuffer(OutputBuffer * cb, InputStream * inStream,
return 0;
}
+void output_buffer_skip(OutputBuffer * cb, unsigned num)
+{
+ int i = outputBufferAbsolute(cb, num);
+ if (i >= 0)
+ cb->begin = i;
+}