diff options
author | Max Kellermann <max@duempel.org> | 2013-08-10 18:02:44 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2013-09-04 18:14:22 +0200 |
commit | 29030b54c98b0aee65fbc10ebf7ba36bed98c02c (patch) | |
tree | 79766830b55ebca38ddbce84d8d548227eedb69e /src/decoder/FlacInput.cxx | |
parent | c9fcc7f14860777458153eb2d13c773ccfa1daa2 (diff) | |
download | mpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.tar.gz mpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.tar.xz mpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.zip |
util/Error: new error passing library
Replaces GLib's GError.
Diffstat (limited to 'src/decoder/FlacInput.cxx')
-rw-r--r-- | src/decoder/FlacInput.cxx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/decoder/FlacInput.cxx b/src/decoder/FlacInput.cxx index 0bb5ec7d7..46f213787 100644 --- a/src/decoder/FlacInput.cxx +++ b/src/decoder/FlacInput.cxx @@ -20,8 +20,9 @@ #include "config.h" #include "FlacInput.hxx" #include "DecoderAPI.hxx" -#include "gcc.h" #include "InputStream.hxx" +#include "util/Error.hxx" +#include "gcc.h" FLAC__StreamDecoderReadStatus FlacInput::Read(FLAC__byte buffer[], size_t *bytes) @@ -47,9 +48,10 @@ FlacInput::Seek(FLAC__uint64 absolute_byte_offset) if (!input_stream->seekable) return FLAC__STREAM_DECODER_SEEK_STATUS_UNSUPPORTED; + ::Error error; if (!input_stream_lock_seek(input_stream, absolute_byte_offset, SEEK_SET, - nullptr)) + error)) return FLAC__STREAM_DECODER_SEEK_STATUS_ERROR; return FLAC__STREAM_DECODER_SEEK_STATUS_OK; |