On 12/11/14 16:43, Vittorio Giovara wrote: > On Tue, Nov 11, 2014 at 1:26 PM, Vittorio Giovara > <[email protected]> wrote: >> From: Luca Barbato <[email protected]> >> >> Prevent an uninitialized data access. >> >> CC: [email protected] >> Bug-Id: CID 703824 / CID 703825 >> --- >> libavcodec/proresenc.c | 8 ++++---- >> 1 file changed, 4 insertions(+), 4 deletions(-) >> >> diff --git a/libavcodec/proresenc.c b/libavcodec/proresenc.c >> index df9b834..7209f34 100644 >> --- a/libavcodec/proresenc.c >> +++ b/libavcodec/proresenc.c >> @@ -758,7 +758,8 @@ static int find_slice_quant(AVCodecContext *avctx, const >> AVFrame *pic, >> const int max_quant = ctx->profile_info->max_quant; >> int error, bits, bits_limit; >> int mbs, prev, cur, new_score; >> - int slice_bits[TRELLIS_WIDTH], slice_score[TRELLIS_WIDTH]; >> + int slice_bits[TRELLIS_WIDTH] = { 0 }; >> + int slice_score[TRELLIS_WIDTH] = { 0 }; >> int overquant; >> uint16_t *qmat; >> int linesize[4], line_add; >> @@ -821,10 +822,9 @@ static int find_slice_quant(AVCodecContext *avctx, >> const AVFrame *pic, >> if (ctx->alpha_bits) >> bits += estimate_alpha_plane(ctx, &error, src, linesize[3], >> mbs_per_slice, q, td->blocks[3]); >> - if (bits > 65000 * 8) { >> + if (bits > 65000 * 8) >> error = SCORE_LIMIT; >> - break; >> - } >> + >> slice_bits[q] = bits; >> slice_score[q] = error; >> } >> -- >> 1.9.3 (Apple Git-50) >> > > ping >
If it is ok for you and for me I guess it fine to push it (nobody complained about = alignment though) lu _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
