On Thu, 05 May 2016 14:45:57 +0200 Anton Khirnov <[email protected]> wrote:
> Quoting Derek Buitenhuis (2016-05-05 14:42:38) > > On 5/4/2016 8:40 PM, wm4 wrote: > > > This fixes behavior with "legitimate" 0-sized packets that appear mid- > > > stream, and which are _not_ flush packets. > > > > I still do not think these packets are "legitimate". > > > > The correct fix is to make sure lavf doesn't return 0-sized packets, no? > > > > Can anyone inform me the reasoning for returning these at all in the first > > place? I haven't found anything yet that fails to decode without 0-sized packets. Filtering them in lavf would be fine with me too. But I don't understand why my sample file has this 0-sized packet. > > I agree that packets that have zero size and nothing else inside are > invalid and should not be passed into lavc or exported from lavf. > > OTOH one can imagine valid packets with no data, but containing side > data. They can already be exported by encoders (specifically by the flac > encoder, to update the extradata at the end of muxing). Yes, that's why I'd like to be careful here. Also, not all API users necessarily use libavformat for demuxing. Anyway, I'm open to both approaches. I still think using 0-sized packets for flushing should actually be discouraged. _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
