From 3ae0d6f4210e370225cf0b9177f6c16d84d9255b Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 22 Sep 2014 08:18:58 +0200 Subject: DecoderBuffer: export the struct Eliminates the functions _new() and _free(). --- src/decoder/plugins/FaadDecoderPlugin.cxx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/decoder/plugins') diff --git a/src/decoder/plugins/FaadDecoderPlugin.cxx b/src/decoder/plugins/FaadDecoderPlugin.cxx index d59309a3a..6a2744243 100644 --- a/src/decoder/plugins/FaadDecoderPlugin.cxx +++ b/src/decoder/plugins/FaadDecoderPlugin.cxx @@ -308,8 +308,8 @@ static std::pair faad_get_file_time(InputStream &is) { DecoderBuffer *buffer = - decoder_buffer_new(nullptr, is, - FAAD_MIN_STREAMSIZE * MAX_CHANNELS); + new DecoderBuffer(nullptr, is, + FAAD_MIN_STREAMSIZE * MAX_CHANNELS); auto duration = faad_song_duration(buffer, is); bool recognized = !duration.IsNegative(); @@ -326,7 +326,7 @@ faad_get_file_time(InputStream &is) NeAACDecClose(decoder); } - decoder_buffer_free(buffer); + delete buffer; return std::make_pair(recognized, duration); } @@ -415,8 +415,8 @@ static void faad_stream_decode(Decoder &mpd_decoder, InputStream &is) { DecoderBuffer *buffer = - decoder_buffer_new(&mpd_decoder, is, - FAAD_MIN_STREAMSIZE * MAX_CHANNELS); + new DecoderBuffer(&mpd_decoder, is, + FAAD_MIN_STREAMSIZE * MAX_CHANNELS); /* create the libfaad decoder */ @@ -427,7 +427,7 @@ faad_stream_decode(Decoder &mpd_decoder, InputStream &is) /* cleanup */ NeAACDecClose(decoder); - decoder_buffer_free(buffer); + delete buffer; } static bool -- cgit v1.2.3