mirror of
https://github.com/esphome/esphome.git
synced 2025-07-29 22:56:37 +00:00
[audio] Fix: Decoder stops unnecessarily after a potential failure is detected. (#8776)
This commit is contained in:
parent
6f8ee65919
commit
032949bc77
@ -171,7 +171,7 @@ AudioDecoderState AudioDecoder::decode(bool stop_gracefully) {
|
||||
|
||||
bytes_available_before_processing = this->input_transfer_buffer_->available();
|
||||
|
||||
if ((this->potentially_failed_count_ > 10) && (bytes_read == 0)) {
|
||||
if ((this->potentially_failed_count_ > 0) && (bytes_read == 0)) {
|
||||
// Failed to decode in last attempt and there is no new data
|
||||
|
||||
if ((this->input_transfer_buffer_->free() == 0) && first_loop_iteration) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user