diff --git a/libAACdec/src/block.cpp b/libAACdec/src/block.cpp index b3d09a6..6a6ae61 100644 --- a/libAACdec/src/block.cpp +++ b/libAACdec/src/block.cpp @@ -372,6 +372,9 @@ AAC_DECODER_ERROR CBlock_ReadSectionData( } sect_len += sect_len_incr; + if (sect_len <= 0) { + return AAC_DEC_PARSE_ERROR; + } top = band + sect_len;