[FFmpeg-devel] [PATCH]Stop demuxing wtv on eof

Paul B Mahol onemda at gmail.com
Thu Oct 2 08:43:27 CEST 2014


On 10/1/14, Peter Ross <pross at xvid.org> wrote:
> On Wed, Oct 01, 2014 at 06:18:56PM +0200, Carl Eugen Hoyos wrote:
>> Hi!
>>
>> Attached patch fixes the wtv regression described in tickets #3991 and
>> #3995
>> for me.
>>
>> Please review, Carl Eugen
>
>> diff --git a/libavformat/wtvdec.c b/libavformat/wtvdec.c
>> index 4cb3295..674ff6e 100644
>> --- a/libavformat/wtvdec.c
>> +++ b/libavformat/wtvdec.c
>> @@ -789,6 +789,8 @@ static int parse_chunks(AVFormatContext *s, int mode,
>> int64_t seekts, int *len_p
>>          len = avio_rl32(pb);
>>          if (len < 32) {
>>              int ret;
>> +            if (avio_feof(pb))
>> +                return AVERROR(EOF);

error code should be AVERROR_EOF.

>>              av_log(s, AV_LOG_WARNING, "encountered broken chunk\n");
>
> Please commit. I have tested it also.
>
> -- Peter
> (A907 E02F A6E5 0CD2 34CD 20D2 6760 79C5 AC40 DD6B)
>


More information about the ffmpeg-devel mailing list