Commit 753b5cf3 authored by Max Kellermann's avatar Max Kellermann Committed by Eric Wong

use clearOutputBuffer()

clearOutputBuffer() also resets currentChunk; this might resolve a theoretical bug. git-svn-id: https://svn.musicpd.org/mpd/trunk@7257 09075e82-0dd4-0310-85a5-a0d7c8717e4f
parent 199ea5f2
......@@ -171,8 +171,7 @@ static int decodeSeek(PlayerControl * pc, DecoderControl * dc,
dc->current_song != pc->current_song) {
stopDecode(dc);
*next = -1;
cb->begin = 0;
cb->end = 0;
clearOutputBuffer(cb);
dc->error = DECODE_ERROR_NOERROR;
dc->start = 1;
waitOnDecode(pc, dc, cb, decodeWaitedOn);
......@@ -607,9 +606,8 @@ void decode(void)
DecoderControl *dc;
cb = &(getPlayerData()->buffer);
clearOutputBuffer(cb);
cb->begin = 0;
cb->end = 0;
pc = &(getPlayerData()->playerControl);
dc = &(getPlayerData()->decoderControl);
dc->error = DECODE_ERROR_NOERROR;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment