aboutsummaryrefslogtreecommitdiffstats
path: root/src/inputPlugins
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-08-26 08:27:07 +0200
committerMax Kellermann <max@duempel.org>2008-08-26 08:27:07 +0200
commitc7384b65ac422e1dd5eadcb06b74931de37a6f58 (patch)
treebec4ca1f705b4920ff983f21c5a73fd71911c24e /src/inputPlugins
parent67bf4b448dad25f2f0c60451f53fcacb0a0bde15 (diff)
downloadmpd-c7384b65ac422e1dd5eadcb06b74931de37a6f58.tar.gz
mpd-c7384b65ac422e1dd5eadcb06b74931de37a6f58.tar.xz
mpd-c7384b65ac422e1dd5eadcb06b74931de37a6f58.zip
eliminate OUTPUT_BUFFER_DC_STOP, OUTPUT_BUFFER_DC_SEEK
(Ab)use the decoder_command enumeration, which has nearly the same values and the same meaning.
Diffstat (limited to 'src/inputPlugins')
-rw-r--r--src/inputPlugins/_flac_common.h2
-rw-r--r--src/inputPlugins/mp3_plugin.c7
2 files changed, 5 insertions, 4 deletions
diff --git a/src/inputPlugins/_flac_common.h b/src/inputPlugins/_flac_common.h
index 21f710628..df9d7a84f 100644
--- a/src/inputPlugins/_flac_common.h
+++ b/src/inputPlugins/_flac_common.h
@@ -171,7 +171,7 @@ static inline int flacSendChunk(FlacData * data)
1, data->chunk,
data->chunk_length, data->time,
data->bitRate,
- data->replayGainInfo) == OUTPUT_BUFFER_DC_STOP)
+ data->replayGainInfo) == DECODE_COMMAND_STOP)
return -1;
return 0;
diff --git a/src/inputPlugins/mp3_plugin.c b/src/inputPlugins/mp3_plugin.c
index 66ca85e2e..3e7e0ea3f 100644
--- a/src/inputPlugins/mp3_plugin.c
+++ b/src/inputPlugins/mp3_plugin.c
@@ -927,21 +927,22 @@ static int mp3Read(mp3DecodeData * data, struct decoder *decoder,
}
if (data->outputPtr >= data->outputBufferEnd) {
- ret = decoder_data(decoder, data->inStream,
+ enum decoder_command cmd;
+ cmd = decoder_data(decoder, data->inStream,
data->inStream->seekable,
data->outputBuffer,
data->outputPtr - data->outputBuffer,
data->elapsedTime,
data->bitRate / 1000,
(replayGainInfo != NULL) ? *replayGainInfo : NULL);
- if (ret == OUTPUT_BUFFER_DC_STOP) {
+ if (cmd == DECODE_COMMAND_STOP) {
data->flush = 0;
return DECODE_BREAK;
}
data->outputPtr = data->outputBuffer;
- if (ret == OUTPUT_BUFFER_DC_SEEK)
+ if (cmd == DECODE_COMMAND_STOP)
break;
}
}