[FFmpeg-devel] [PATCH] ffprobe: do not try to decode empty packets.

Stefano Sabatini stefasab at gmail.com
Sat Apr 21 14:59:30 CEST 2012

On date Saturday 2012-04-21 14:08:07 +0200, Nicolas George encoded:
> Le tridi 3 floréal, an CCXX, Stefano Sabatini a écrit :
> > OK, although I think this exposes a bug in the H.264 decoder, see:
> > http://thread.gmane.org/20120214162613.GA30952@titan.codemill.se
> You are right, this is the same issue. I believe my patch was simpler than
> the ones there.
> Also, I am not sure about this, that you wrote then:
> # Indeed from my reading of the documentation there is nothing wrong
> # about passing video packets with size of 0, and the expected behavior
> # should be to just ignore such packets
> Passing video packets means flushing the decoder, and as such can cause
> changes in the internal state, such as freeing frames that can no longer be
> used as reference.

Yes, but maybe the decoder should just ignore non-NULL packets with
size == 0.

> On the other hand, the fact that some files caused a segfault is worrisome,
> as the same result could probably be caused by specially crafted files.
> > (also this patch seems to fix ticket #997, you may add a note in the
> > commit message).
FFmpeg = Free Furious Mystic Portentous Elastic Game

More information about the ffmpeg-devel mailing list