forked from mia/Aegisub
Fix overflow issues with truncated pcm files
This commit is contained in:
parent
f811f7e363
commit
bebc024fa0
1 changed files with 1 additions and 1 deletions
|
@ -167,7 +167,7 @@ public:
|
|||
auto chunk_fcc = Read<ChunkId>(&data_left);
|
||||
auto chunk_size = Impl::chunk_size(Read<DataSize>(&data_left));
|
||||
|
||||
data_left -= chunk_size;
|
||||
data_left -= std::min(chunk_size, data_left);
|
||||
|
||||
if (chunk_fcc == Impl::fmt_id()) {
|
||||
if (channels || sample_rate || bytes_per_sample)
|
||||
|
|
Loading…
Reference in a new issue