Atrac: Return an error if there's no data chunk.

This commit is contained in:
Unknown W. Brackets 2015-10-18 13:27:52 -07:00
parent c14d1f7353
commit 522a1743f4

View File

@ -679,6 +679,11 @@ int Atrac::Analyze() {
return ATRAC_ERROR_UNKNOWN_FORMAT;
}
if (!bfoundData) {
WARN_LOG_REPORT(ME, "Atrac buffer never had data chunk");
return ATRAC_ERROR_SIZE_TOO_SMALL;
}
// set the loopStartSample and loopEndSample by loopinfo
if (loopinfoNum > 0) {
loopStartSample = loopinfo[0].startSample;