Skip to content

Commit

Permalink
Avoid index-out-of-bounds in processDrcTime
Browse files Browse the repository at this point in the history
Fixes: 17638/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_LIBFDK_AAC_fuzzer-5699860921057280

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
  • Loading branch information
mstorsjo committed Oct 2, 2019
1 parent e3bc3e4 commit f3f3b69
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions libDRCdec/src/drcGainDec_process.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -308,6 +308,8 @@ processDrcTime(HANDLE_DRC_GAIN_DECODER hGainDec, const int activeDrcIndex,
pLinearNodeBuffer[pActiveDrc->lnbIndexForChannel[c][lnbIx] + b]);
else
pLnbPrevious = pDummyLnb;
if (pLnbPrevious->nNodes[lnbIx] <= 0 || pLnbPrevious->nNodes[lnbIx] > 16)
return DE_NOT_OK;
nodePrevious =
pLnbPrevious->linearNode[lnbIx][pLnbPrevious->nNodes[lnbIx] - 1];
nodePrevious.time -= hGainDec->frameSize;
Expand Down

0 comments on commit f3f3b69

Please sign in to comment.