decoder/flac: check for errors only after _process_single()
The only other libFLAC call (seek) does not produce fatal errors.
This commit is contained in:
parent
851fb16e7c
commit
d95db28695
@ -286,16 +286,14 @@ flac_decoder_loop(struct flac_data *data, FLAC__StreamDecoder *flac_dec,
|
|||||||
/* end of this sub track */
|
/* end of this sub track */
|
||||||
break;
|
break;
|
||||||
|
|
||||||
if (!FLAC__stream_decoder_process_single(flac_dec)) {
|
if (!FLAC__stream_decoder_process_single(flac_dec) &&
|
||||||
cmd = decoder_get_command(decoder);
|
decoder_get_command(decoder) == DECODE_COMMAND_NONE) {
|
||||||
if (cmd != DECODE_COMMAND_SEEK)
|
/* a failure that was not triggered by a
|
||||||
break;
|
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
|
static FLAC__StreamDecoderInitStatus
|
||||||
|
Loading…
Reference in New Issue
Block a user