[FFmpeg-devel] [PATCH] Fix floating point exception computing duration when no time-base is set
Mon Sep 14 23:36:51 CEST 2009
On Mon, Sep 14, 2009 at 2:19 PM, Reimar D?ffinger
<Reimar.Doeffinger at gmx.de> wrote:
> Uh, why not check that in whatever place sample_rate gets set (your
> users don't have direct access to AVCodecContext after all, do they?)
I can check the AVCodecContext when the sample_rate gets set, but our
library can't know which AVStream that codec is being used with. It
could be used with several AVStream objects if the same codec's output
is going to multiple muxers.
> That sounds like a very unlikely scenario to me, seems more likely that
> nothing bad happens so they think everything is ok and silently create
> broken files. And I'm not even going into writing a signal handler to
> deal with it, though that definitely is _possible_, too...
Unlikely, yes. Does it even happen? -- well I sent the patch because
we had a user complaining about core-dumps and this was the root cause
As for broken files, that is theorietically possible I guess, but
shouldn't the packet muxers be checking for a duration > 0 if they
require duration to be set in the container? The bug I'm talking
about happens on demuxing, not muxing.
Lastly, I could write a signal handler, true, but that path is dark
and filled with evil goblins....
xu?ggle (z?' gl) v. To freely encode, decode, and experience audio and video.
Use Xuggle to get the power of FFmpeg in Java.
More information about the ffmpeg-devel