[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 20:28:04 CET 2009

On 11/19/2009 09:12 AM, Ronald S. Bultje wrote:
> Hi,
> On Thu, Nov 19, 2009 at 1:45 AM, Baptiste Coudurier
> <baptiste.coudurier at gmail.com>  wrote:
>> I don't like the<  0 check, but I guess we don't have much choice here.
> Er...
> A) AVURational (bikeshed!!!!111)
> B) uint32_t num = READ_BE32(..), den = READ_BE32(..);
>      if (num&  0x80000000 || den&  0x80000000) { den>>= 1; num>>= 1 }
> It's not like this 32th bit is suddenly gonna cause a movie to go out of sync...
> And even if you don't do that, don't ever set it to 1. DO NO SET IT TO
> 1. 1 is wrong. It is never correct. If you can't parse it, error out.

In the 0 case, the file can still be demuxed to raw, it would be stupid 
to error out, I'm against erroring out.

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

More information about the ffmpeg-devel mailing list