[FFmpeg-devel] [RFC] Change fallthrough logic for read_seek to be based on return value
Joakim Plate
elupus at ecce.se
Tue Sep 13 00:19:02 CEST 2011
On Mon, 12 Sep 2011 23:36:59 +0200, Reimar Döffinger wrote:
> On Mon, Sep 12, 2011 at 10:11:09PM +0200, Joakim Plate wrote:
>> The gxf change was really the only change needed to make fate pass. However
>> that change actually look wrong. So maybe fate should be updated there
>> instead.
>
> Why do you think it looks wrong? Index in GXF is rather special, in
> particular it is not complete, so it can make sense to retry with
> other methods.
>
>> @@ -1810,10 +1810,12 @@ int av_seek_frame(AVFormatContext *s, int stream_index, int64_t timestamp, int f
>> if (s->iformat->read_seek)
>> ret = s->iformat->read_seek(s, stream_index, timestamp, flags);
>> else
>> - ret = -1;
>> + ret = AVERROR(ENOSYS);
>> if (ret >= 0) {
>> return 0;
>> }
>> + if (ret != AVERROR(ENOSYS))
>> + return -1;
>
> What's the reason for not returning ret?
None. Here is an updated patch where i've looked through some more
read_seek implementations. Some where it return'ed 0 to avoid
the retry even when it had an error.
/Joakim
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-Change-fallthrough-logic-for-read_seek-to-be-based-o.patch
Type: text/x-patch
Size: 4939 bytes
Desc: Attached file: 0002-Change-fallthrough-logic-for-read_seek-to-be-based-o.patch
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20110913/696c327c/attachment.bin>
More information about the ffmpeg-devel
mailing list