[FFmpeg-devel] [PATCH] Fix possible SIGFPEs with bad mov timings. Based on chromium patch 35_mov_bad_timings.patch

Baptiste Coudurier baptiste.coudurier
Thu Nov 19 22:15:56 CET 2009


On 11/19/2009 01:10 PM, Albert J. Wong (???) wrote:
> On Thu, Nov 19, 2009 at 11:52 AM, Ronald S. Bultje<rsbultje at gmail.com>wrote:
>
>> Hi,
>>
>> On Thu, Nov 19, 2009 at 2:37 PM, Albert J. Wong (???)
>> <ajwong at chromium.org>  wrote:
>>> How about something like
>>>
>>> if (c->time_scale<  0)
>>>   return AVERROR_INVALIDDATA;
>>> else if (!c->time_scale)
>>>   c->time_scale = 1;
>>> if (sc->time_scale<=0) {
>>>    // the log message whatever that was...
>>>   sc_time_scape = c->time_scale;
>>> }
>>>
>>> ?
>>>
>>> That lets us handle the raw case, and chooses to ignore the potentially
>>> negative values.  Is there's a better middle ground that I'm missing?
>>
>> Putting this in any (=>  every) demuxer is silly, imo.
>>
>>
> What's a better solution then?

Handling this problem in av_set_pts_info, I think.

-- 
Baptiste COUDURIER
Key fingerprint                 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA
FFmpeg maintainer                                  http://www.ffmpeg.org



More information about the ffmpeg-devel mailing list