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

Albert J. Wong (王重傑) ajwong
Thu Nov 19 22:10:14 CET 2009


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?



More information about the ffmpeg-devel mailing list