History

avcodec/cfhdenc: Clear dwt_tmp

This occurs on a 32x32 input Fixes: use of uninitialized value Fixes: 70897/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_CFHD_fuzzer-5960860961406976

Michael Niedermayer committed 2 years ago

Commit 9de721d1 parent 7eeeda71 file · +1 −1Browse files

Unified · Split

libavcodec/cfhdenc.c+1−1
@@ -285,7 +285,7 @@ static av_cold int cfhd_encode_init(AVCodecContext *avctx) · 284 unmodified lines
285285 s->plane[i].dwt_buf =
286286 av_calloc(h8 * 8 * w8 * 8, sizeof(*s->plane[i].dwt_buf));
287287 s->plane[i].dwt_tmp =
288− av_malloc_array(h8 * 8 * w8 * 8, sizeof(*s->plane[i].dwt_tmp));
288+ av_calloc(h8 * 8 * w8 * 8, sizeof(*s->plane[i].dwt_tmp));
289289 if (!s->plane[i].dwt_buf || !s->plane[i].dwt_tmp)
290290 return AVERROR(ENOMEM);
291291

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t