[FFmpeg-devel] [PATCH] Fix DV uninitialized reads
Tue Sep 22 17:46:52 CEST 2009
On Tue, Sep 22, 2009 at 10:20:51AM +0200, Reimar D?ffinger wrote:
> On Tue, Sep 22, 2009 at 12:19:29AM -0700, Baptiste Coudurier wrote:
> > Hi Reimar,
> > On 09/21/2009 05:40 AM, Reimar D?ffinger wrote:
> > > Hello,
> > > I think this fixes the uninitialized data in the DV encoder that causes
> > > sporadic "make test" failures, at least valgrind complains no longer.
> > > Quick measurements with "time" indicate a slowdown by about 0.8%.
> > > regression test values for the encoded files changes (memset to 0
> > > instead of 0xff might avoid that though), but the decoded data
> > > stays the same - so at least for the cases "make test" covers it is
> > > correct.
> > I assume 0xff is correct according to specs, right ?
> I don't think the specs say anything about it (except for the header
> DIFs), but since the current code pads the header and audio DIFs by 0xff
> it is consistent... (though flush_put_bits will pad with 0, so it is not
> that consistent).
maybe flush/align_put_bits should have a parameter that switches betweem 0/1
padding, could also be used to simplify ff_mpeg4_stuffing() and probably
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Observe your enemies, for they first find out your faults. -- Antisthenes
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: Digital signature
More information about the ffmpeg-devel