From fc2a14b0fad0c071c8ce59450d3e6fff10a2df8c Mon Sep 17 00:00:00 2001 From: Christopher Snowhill Date: Sun, 23 Mar 2025 20:03:44 -0700 Subject: [PATCH] Bug Fix: Free memory buffers used by minimp3 This was being leaked when playing static, seekable files. Oops. Signed-off-by: Christopher Snowhill --- Plugins/minimp3/MP3Decoder.m | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Plugins/minimp3/MP3Decoder.m b/Plugins/minimp3/MP3Decoder.m index 5c82fc42d..8e04866f9 100644 --- a/Plugins/minimp3/MP3Decoder.m +++ b/Plugins/minimp3/MP3Decoder.m @@ -276,6 +276,9 @@ static int mp3_seek_callback(uint64_t position, void *user_data) { } - (void)close { + if(seekable) { + mp3dec_ex_close(&_decoder_ex); + } if(_source) { _source = nil; }