aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/decoder/flac_decoder_plugin.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/src/decoder/flac_decoder_plugin.c b/src/decoder/flac_decoder_plugin.c
index e8e93ff37..9dc1898d5 100644
--- a/src/decoder/flac_decoder_plugin.c
+++ b/src/decoder/flac_decoder_plugin.c
@@ -286,16 +286,14 @@ flac_decoder_loop(struct flac_data *data, FLAC__StreamDecoder *flac_dec,
/* end of this sub track */
break;
- if (!FLAC__stream_decoder_process_single(flac_dec)) {
- cmd = decoder_get_command(decoder);
- if (cmd != DECODE_COMMAND_SEEK)
- break;
+ if (!FLAC__stream_decoder_process_single(flac_dec) &&
+ decoder_get_command(decoder) == DECODE_COMMAND_NONE) {
+ /* a failure that was not triggered by a
+ decoder command */
+ flacPrintErroredState(FLAC__stream_decoder_get_state(flac_dec));
+ break;
}
}
-
- if (cmd != DECODE_COMMAND_STOP) {
- flacPrintErroredState(FLAC__stream_decoder_get_state(flac_dec));
- }
}
static FLAC__StreamDecoderInitStatus