From f1027ed198535ce16cfb9c83ac802788ec750488 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Wed, 23 Oct 2013 21:22:29 +0200 Subject: InputStream: add method Rewind() --- src/decoder/FfmpegDecoderPlugin.cxx | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'src/decoder/FfmpegDecoderPlugin.cxx') diff --git a/src/decoder/FfmpegDecoderPlugin.cxx b/src/decoder/FfmpegDecoderPlugin.cxx index 5092bdf9e..cba7f5e2d 100644 --- a/src/decoder/FfmpegDecoderPlugin.cxx +++ b/src/decoder/FfmpegDecoderPlugin.cxx @@ -31,15 +31,6 @@ #include "util/Domain.hxx" #include "LogV.hxx" -#include -#include -#include -#include -#include -#include -#include -#include - extern "C" { #include #include @@ -50,6 +41,9 @@ extern "C" { #include } +#include +#include + static constexpr Domain ffmpeg_domain("ffmpeg"); /* suppress the ffmpeg compatibility macro */ @@ -352,7 +346,7 @@ ffmpeg_probe(Decoder *decoder, struct input_stream *is) unsigned char buffer[BUFFER_SIZE]; size_t nbytes = decoder_read(decoder, is, buffer, BUFFER_SIZE); - if (nbytes <= PADDING || !is->LockSeek(0, SEEK_SET, error)) + if (nbytes <= PADDING || !is->LockRewind(error)) return nullptr; /* some ffmpeg parsers (e.g. ac3_parser.c) read a few bytes -- cgit v1.2.3