diff options
author | Max Kellermann <max@duempel.org> | 2013-11-28 00:05:26 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2013-11-28 00:05:26 +0100 |
commit | 47c50c079d0abf3d807815eb3c4b43dd6544b93f (patch) | |
tree | d0bb499fafb18481ecaff6b4f8311a71a255082c /src | |
parent | 3b0fea5fae8ce52d2d4aa9ae7accc1f7f33592e1 (diff) |
decoder/ffmpeg: use IgnoreError instead of local Error instance
Diffstat (limited to 'src')
-rw-r--r-- | src/decoder/FfmpegDecoderPlugin.cxx | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/decoder/FfmpegDecoderPlugin.cxx b/src/decoder/FfmpegDecoderPlugin.cxx index 1b62eae57..6add90045 100644 --- a/src/decoder/FfmpegDecoderPlugin.cxx +++ b/src/decoder/FfmpegDecoderPlugin.cxx @@ -120,8 +120,7 @@ mpd_ffmpeg_stream_seek(void *opaque, int64_t pos, int whence) if (whence == AVSEEK_SIZE) return stream->input.size; - Error error; - if (!stream->input.LockSeek(pos, whence, error)) + if (!stream->input.LockSeek(pos, whence, IgnoreError())) return -1; return stream->input.offset; @@ -342,11 +341,9 @@ ffmpeg_probe(Decoder *decoder, InputStream &is) PADDING = 16, }; - Error error; - unsigned char buffer[BUFFER_SIZE]; size_t nbytes = decoder_read(decoder, is, buffer, BUFFER_SIZE); - if (nbytes <= PADDING || !is.LockRewind(error)) + if (nbytes <= PADDING || !is.LockRewind(IgnoreError())) return nullptr; /* some ffmpeg parsers (e.g. ac3_parser.c) read a few bytes |