Re: [FFmpeg-devel] [PATCH] avcodec/truemotion2: Avoid duplicating array, fix memleak

2020-08-29 Thread Paul B Mahol
On 8/29/20, Andreas Rheinhardt wrote: > TrueMotion 2.0 uses Huffmann trees. To parse them, the decoder allocates > arrays for the codes, their lengths and their value; afterwards a VLC > table is initialized using these values. If everything up to this point > succeeds, a new buffer of the same si

[FFmpeg-devel] [PATCH] avcodec/truemotion2: Avoid duplicating array, fix memleak

2020-08-29 Thread Andreas Rheinhardt
TrueMotion 2.0 uses Huffmann trees. To parse them, the decoder allocates arrays for the codes, their lengths and their value; afterwards a VLC table is initialized using these values. If everything up to this point succeeds, a new buffer of the same size as the already allocated arrays for the valu