Skip to content

Commit 47a1d62

Browse files
authored
add stopSong() if local file is interrupted and typo correction
1 parent 3a3a8b7 commit 47a1d62

File tree

4 files changed

+8
-7
lines changed

4 files changed

+8
-7
lines changed

src/Audio.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
*
44
* Created on: Oct 26.2018
55
*
6-
* Version 2.0.7j
7-
* Updated on: Jan 06.2023
6+
* Version 2.0.7k
7+
* Updated on: Jan 08.2023
88
* Author: Wolle (schreibfaul1)
99
*
1010
*/
@@ -301,6 +301,7 @@ Audio::~Audio() {
301301
}
302302
//---------------------------------------------------------------------------------------------------------------------
303303
void Audio::setDefaults() {
304+
stopSong();
304305
initInBuff(); // initialize InputBuffer if not already done
305306
InBuff.resetBuffer();
306307
MP3Decoder_FreeBuffers();
@@ -3799,7 +3800,7 @@ int Audio::sendBytes(uint8_t* data, size_t len) {
37993800
}
38003801
if(m_codec == CODEC_FLAC){
38013802
m_validSamples = FLACGetOutputSamps() / getChannels();
3802-
char* st = FLACgetStreanTitle();
3803+
char* st = FLACgetStreamTitle();
38033804
if(st){
38043805
AUDIO_INFO(st);
38053806
if(audio_showstreamtitle) audio_showstreamtitle(st);

src/Audio.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* Audio.h
33
*
44
* Created on: Oct 28,2018
5-
* Updated on: Jan 06,2023
5+
* Updated on: Jan 08,2023
66
* Author: Wolle (schreibfaul1)
77
*/
88

src/flac_decoder/flac_decoder.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* adapted to ESP32
55
*
66
* Created on: Jul 03,2020
7-
* Updated on: Nov 25,2022
7+
* Updated on: Jan 08,2023
88
*
99
* Author: Wolle
1010
*

src/flac_decoder/flac_decoder.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* flac_decoder.h
33
*
44
* Created on: Jul 03,2020
5-
* Updated on: Nov 26,2022
5+
* Updated on: Jan 08,2023
66
*
77
* Author: wolle
88
*
@@ -145,7 +145,7 @@ typedef struct FLACFrameHeader_t {
145145
int FLACFindSyncWord(unsigned char *buf, int nBytes);
146146
boolean FLACFindMagicWord(unsigned char* buf, int nBytes);
147147
boolean FLACFindStreamTitle(unsigned char* buf, int nBytes);
148-
char* FLACgetStreanTitle();
148+
char* FLACgetStreamTitle();
149149
int FLACparseOggHeader(unsigned char *buf);
150150
bool FLACDecoder_AllocateBuffers(void);
151151
void FLACDecoder_ClearBuffer();

0 commit comments

Comments
 (0)