From 3abf599c4f8b04bed4ed67084588204f65a644d0 Mon Sep 17 00:00:00 2001 From: jacqueline Date: Tue, 7 Nov 2023 15:57:56 +1100 Subject: Improve memory usage of mad codec - fix leaks - ensure the synth data is always in internal ram --- src/codecs/include/mad.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/codecs/include') diff --git a/src/codecs/include/mad.hpp b/src/codecs/include/mad.hpp index 994e989c..813aa86d 100644 --- a/src/codecs/include/mad.hpp +++ b/src/codecs/include/mad.hpp @@ -45,9 +45,9 @@ class MadMp3Decoder : public ICodec { std::shared_ptr input_; SourceBuffer buffer_; - mad_stream* stream_; - mad_frame* frame_; - mad_synth* synth_; + std::unique_ptr stream_; + std::unique_ptr frame_; + std::unique_ptr synth_; int current_sample_; bool is_eof_; -- cgit v1.2.3