aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/FlacInput.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-09-05 00:06:31 +0200
committerMax Kellermann <max@duempel.org>2013-09-05 00:23:14 +0200
commit7d0269d2cec68c7e55df5b6db3d2266741534b17 (patch)
tree613f5d7b03bc9624f15167c76f8f4309603944cc /src/decoder/FlacInput.cxx
parent52ffdb0a55e43153fa9fc1189316884a630df700 (diff)
downloadmpd-7d0269d2cec68c7e55df5b6db3d2266741534b17.tar.gz
mpd-7d0269d2cec68c7e55df5b6db3d2266741534b17.tar.xz
mpd-7d0269d2cec68c7e55df5b6db3d2266741534b17.zip
InputLegacy: move functions to the input_stream class
Diffstat (limited to 'src/decoder/FlacInput.cxx')
-rw-r--r--src/decoder/FlacInput.cxx8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/decoder/FlacInput.cxx b/src/decoder/FlacInput.cxx
index 46f213787..947177cde 100644
--- a/src/decoder/FlacInput.cxx
+++ b/src/decoder/FlacInput.cxx
@@ -31,7 +31,7 @@ FlacInput::Read(FLAC__byte buffer[], size_t *bytes)
*bytes = r;
if (r == 0) {
- if (input_stream_lock_eof(input_stream) ||
+ if (input_stream->LockIsEOF() ||
(decoder != nullptr &&
decoder_get_command(decoder) != DECODE_COMMAND_NONE))
return FLAC__STREAM_DECODER_READ_STATUS_END_OF_STREAM;
@@ -49,9 +49,7 @@ FlacInput::Seek(FLAC__uint64 absolute_byte_offset)
return FLAC__STREAM_DECODER_SEEK_STATUS_UNSUPPORTED;
::Error error;
- if (!input_stream_lock_seek(input_stream,
- absolute_byte_offset, SEEK_SET,
- error))
+ if (!input_stream->LockSeek(absolute_byte_offset, SEEK_SET, error))
return FLAC__STREAM_DECODER_SEEK_STATUS_ERROR;
return FLAC__STREAM_DECODER_SEEK_STATUS_OK;
@@ -83,7 +81,7 @@ FlacInput::Eof()
return (decoder != nullptr &&
decoder_get_command(decoder) != DECODE_COMMAND_NONE &&
decoder_get_command(decoder) != DECODE_COMMAND_SEEK) ||
- input_stream_lock_eof(input_stream);
+ input_stream->LockIsEOF();
}
void