mirror of
https://github.com/xenia-project/FFmpeg.git
synced 2024-12-01 15:31:24 +00:00
avcodec/cfhd: clear idwt_buf on allocation
This avoids use of uninitialized variables and might make bugs in general easier to reproduce Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
f90c9c306f
commit
5fb6e39dd1
@ -182,7 +182,7 @@ static int alloc_buffers(AVCodecContext *avctx)
|
||||
w2 = w4 * 2;
|
||||
h2 = h4 * 2;
|
||||
|
||||
s->plane[i].idwt_buf = av_malloc_array(height * stride, sizeof(*s->plane[i].idwt_buf));
|
||||
s->plane[i].idwt_buf = av_mallocz_array(height * stride, sizeof(*s->plane[i].idwt_buf));
|
||||
s->plane[i].idwt_tmp = av_malloc_array(height * stride, sizeof(*s->plane[i].idwt_tmp));
|
||||
if (!s->plane[i].idwt_buf || !s->plane[i].idwt_tmp) {
|
||||
return AVERROR(ENOMEM);
|
||||
|
Loading…
Reference in New Issue
Block a user