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/input/RewindInputPlugin.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 '')
-rw-r--r-- | src/input/RewindInputPlugin.cxx | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/input/RewindInputPlugin.cxx b/src/input/RewindInputPlugin.cxx index 7a88d4f52..bd4f01261 100644 --- a/src/input/RewindInputPlugin.cxx +++ b/src/input/RewindInputPlugin.cxx @@ -66,7 +66,7 @@ struct RewindInputStream { } ~RewindInputStream() { - input_stream_close(input); + input->Close(); } /** @@ -114,7 +114,7 @@ input_rewind_check(struct input_stream *is, Error &error) { RewindInputStream *r = (RewindInputStream *)is; - return input_stream_check(r->input, error); + return r->input->Check(error); } static void @@ -131,7 +131,7 @@ input_rewind_tag(struct input_stream *is) { RewindInputStream *r = (RewindInputStream *)is; - return input_stream_tag(r->input); + return r->input->ReadTag(); } static bool @@ -139,7 +139,7 @@ input_rewind_available(struct input_stream *is) { RewindInputStream *r = (RewindInputStream *)is; - return input_stream_available(r->input); + return r->input->IsAvailable(); } static size_t @@ -165,7 +165,7 @@ input_rewind_read(struct input_stream *is, void *ptr, size_t size, } else { /* pass method call to underlying stream */ - size_t nbytes = input_stream_read(r->input, ptr, size, error); + size_t nbytes = r->input->Read(ptr, size, error); if (r->input->offset > (goffset)sizeof(r->buffer)) /* disable buffering */ @@ -190,7 +190,7 @@ input_rewind_eof(struct input_stream *is) { RewindInputStream *r = (RewindInputStream *)is; - return !r->ReadingFromBuffer() && input_stream_eof(r->input); + return !r->ReadingFromBuffer() && r->input->IsEOF(); } static bool @@ -213,8 +213,7 @@ input_rewind_seek(struct input_stream *is, goffset offset, int whence, return true; } else { - bool success = input_stream_seek(r->input, offset, whence, - error); + bool success = r->input->Seek(offset, whence, error); r->CopyAttributes(); /* disable the buffer, because r->input has left the |