earlephilhower / ESP8266Audio

Arduino library to play MOD, WAV, FLAC, MIDI, RTTTL, MP3, and AAC files on I2S DACs or with a software emulated delta-sigma DAC on the ESP8266 and ESP32
GNU General Public License v3.0
2.01k stars 432 forks source link

ESP32 I2S DMA Buffer Memory Leak issues? #488

Open yihua-wang opened 2 years ago

yihua-wang commented 2 years ago

https://github.com/earlephilhower/ESP8266Audio/blob/73a1821aba9d41c70a05d59fbb11bfbf0316c866/src/AudioOutputI2S.cpp#L351

yihua-wang commented 2 years ago

https://github.com/earlephilhower/ESP8266Audio/blob/73a1821aba9d41c70a05d59fbb11bfbf0316c866/src/AudioOutputI2S.cpp#L102

softhack007 commented 2 years ago

Maybe no memory leak, however I see the problem that the class destructor may miss to uninstall the i2s driver, in case that out->stop() is used before delete. Nice catch 👍

FedericoBusero commented 1 year ago

See https://github.com/earlephilhower/ESP8266Audio/pull/568