Commit 774417f1 authored by Max Kellermann's avatar Max Kellermann

decoder: ignore decoder_data() calls with length==0

Pushing buffers with a zero length into the MPD core causes failures; don't let them pass beyond the decoder plugi API.
parent 63c3ebee
......@@ -194,7 +194,8 @@ decoder_data(struct decoder *decoder,
assert(dc.state == DECODE_STATE_DECODE);
if (dc.command == DECODE_COMMAND_STOP ||
dc.command == DECODE_COMMAND_SEEK)
dc.command == DECODE_COMMAND_SEEK ||
length == 0)
return dc.command;
if (is != NULL && !decoder->stream_tag_sent) {
......
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