History

avcodec/hevcdec: Check ref frame

Fixes: NULL pointer dereferences Fixes: 68197/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_HEVC_fuzzer-6382538823106560

Michael Niedermayer committed 2 years ago

Commit 5eb05f41 parent 4c8a6631 file · +2 −2Browse files

Showing the changes to libavcodec (1 of 1 file). Show all

Unified · Split

libavcodec/hevcdec.c+2−2
@@ -1969,13 +1969,13 @@ static void hls_prediction_unit(HEVCLocalContext *lc, int x0, int y0, · 1968 unmodified lines
19691969
19701970 if (current_mv.pred_flag & PF_L0) {
19711971 ref0 = refPicList[0].ref[current_mv.ref_idx[0]];
1972− if (!ref0 || !ref0->frame->data[0])
1972+ if (!ref0 || !ref0->frame)
19731973 return;
19741974 hevc_await_progress(s, ref0, &current_mv.mv[0], y0, nPbH);
19751975 }
19761976 if (current_mv.pred_flag & PF_L1) {
19771977 ref1 = refPicList[1].ref[current_mv.ref_idx[1]];
1978− if (!ref1 || !ref1->frame->data[0])
1978+ if (!ref1 || !ref1->frame)
19791979 return;
19801980 hevc_await_progress(s, ref1, &current_mv.mv[1], y0, nPbH);
19811981 }

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