[FFmpeg-devel] Fix coredump when writing trailer to file with no streams added
Thu Jun 19 21:55:11 CEST 2008
On Thu, Jun 19, 2008 at 03:51:00PM -0400, Art Clarke wrote:
> On Thu, Jun 19, 2008 at 3:24 PM, Michael Niedermayer <michaelni at gmx.at>
> > On Thu, Jun 19, 2008 at 01:40:06PM -0400, Art Clarke wrote:
> > > Hi there,
> > >
> > > Ffmpeg core-dumps if you do an av_write_header() and then an
> > > av_write_trailer() without first adding at least one stream to the output
> > > file.
> > >
> > > While in theory users should NEVER output a file with no streams in it,
> > > core-dumping seems like the wrong thing to do. The fix just checks to
> > make
> > > sure there is at least one stream before we start returning cached
> > packets
> > > to write.
> > >
> > > Also attached is a test case file that generates the crash before the
> > fix,
> > > and shows that everything runs smoothly after the fix.
> > >
> > > Please let me know if this passes the bar for a fix, is rejected, or if
> > in
> > > between, what I need to do to fix it up right.
> > this check can be simplified
> > [...]
> > --
> > Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
> Fair enough. Attempt #2. Same test case applies.
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Opposition brings concord. Out of discord comes the fairest harmony.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: Digital signature
More information about the ffmpeg-devel