Skip to content

Commit c3cf926

Browse files
authored
Merge pull request #6230 from jepler/audio-fix-looping
MP3Decoder: Accurately inform when no more data
2 parents 076d9f7 + 0da10d8 commit c3cf926

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -400,7 +400,7 @@ jobs:
400400
id: idf-cache
401401
with:
402402
path: ${{ github.workspace }}/.idf_tools
403-
key: ${{ runner.os }}-idf-tools-${{ hashFiles('.git/modules/ports/espressif/esp-idf/HEAD') }}-20210923
403+
key: ${{ runner.os }}-idf-tools-${{ hashFiles('.git/modules/ports/espressif/esp-idf/HEAD') }}-20220404
404404
- name: Clone IDF submodules
405405
run: |
406406
(cd $IDF_PATH && git submodule update --init)

shared-module/audiomp3/MP3Decoder.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ audioio_get_buffer_result_t audiomp3_mp3file_get_buffer(audiomp3_mp3file_obj_t *
364364
}
365365

366366
self->samples_decoded += *buffer_length / sizeof(int16_t);
367-
return GET_BUFFER_MORE_DATA;
367+
return mp3file_find_sync_word(self) ? GET_BUFFER_MORE_DATA : GET_BUFFER_DONE;
368368
}
369369

370370
void audiomp3_mp3file_get_buffer_structure(audiomp3_mp3file_obj_t *self, bool single_channel_output,

0 commit comments

Comments
 (0)