diff options
author | Max Kellermann <max@duempel.org> | 2013-09-05 00:06:31 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2013-09-05 00:23:14 +0200 |
commit | 7d0269d2cec68c7e55df5b6db3d2266741534b17 (patch) | |
tree | 613f5d7b03bc9624f15167c76f8f4309603944cc /src/decoder/ModplugDecoderPlugin.cxx | |
parent | 52ffdb0a55e43153fa9fc1189316884a630df700 (diff) | |
download | mpd-7d0269d2cec68c7e55df5b6db3d2266741534b17.tar.gz mpd-7d0269d2cec68c7e55df5b6db3d2266741534b17.tar.xz mpd-7d0269d2cec68c7e55df5b6db3d2266741534b17.zip |
InputLegacy: move functions to the input_stream class
Diffstat (limited to 'src/decoder/ModplugDecoderPlugin.cxx')
-rw-r--r-- | src/decoder/ModplugDecoderPlugin.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/decoder/ModplugDecoderPlugin.cxx b/src/decoder/ModplugDecoderPlugin.cxx index b95736bf8..0305b582d 100644 --- a/src/decoder/ModplugDecoderPlugin.cxx +++ b/src/decoder/ModplugDecoderPlugin.cxx @@ -20,6 +20,7 @@ #include "config.h" #include "ModplugDecoderPlugin.hxx" #include "DecoderAPI.hxx" +#include "InputStream.hxx" #include "TagHandler.hxx" #include <glib.h> @@ -37,7 +38,7 @@ static constexpr goffset MODPLUG_FILE_LIMIT = 100 * 1024 * 1024; static GByteArray * mod_loadfile(struct decoder *decoder, struct input_stream *is) { - const goffset size = input_stream_get_size(is); + const goffset size = is->GetSize(); if (size == 0) { g_warning("file is empty"); @@ -63,7 +64,7 @@ mod_loadfile(struct decoder *decoder, struct input_stream *is) size_t ret = decoder_read(decoder, is, data, MODPLUG_READ_BLOCK); if (ret == 0) { - if (input_stream_lock_eof(is)) + if (is->LockIsEOF()) /* end of file */ break; @@ -125,7 +126,7 @@ mod_decode(struct decoder *decoder, struct input_stream *is) assert(audio_format.IsValid()); decoder_initialized(decoder, audio_format, - input_stream_is_seekable(is), + is->IsSeekable(), ModPlug_GetLength(f) / 1000.0); do { |