[FFmpeg-devel] [PATCH] mpegts: Return AVERROR(EAGAIN) instead of -1 if there isn't enough data

Martin Storsjö martin
Fri Oct 15 23:34:55 CEST 2010

On Fri, 15 Oct 2010, Luca Barbato wrote:

> On 10/15/2010 05:38 PM, Ronald S. Bultje wrote:
> > It's probably OK. Is there a particular reason that returning anything
> > else than EAGAIN only caused issues for mpegts, as opposed to, say,
> > RTP/ASF?

No, ideally, we'd need to make sure all depacketizers return this (or any 
other consistent error code) for this condition, so that we can 
distinguish between this and a real error (that we'd might want to 
propagate up). Most new depacketizers committed during the gsoc already 
are returning this error code for this situation, and this case just was 
one I ran into while doing some testing on mpegts/rtp data.

> The idea is to have a quick path for the reordering buffer depending on the
> return value from the parse function.
> Patch ok IMHO.


// Martin

More information about the ffmpeg-devel mailing list