Fix file_view::read_at

This commit is contained in:
oltolm 2023-11-10 17:40:17 +01:00 committed by GitHub
parent 71f497947e
commit 8c0debfe65
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3540,7 +3540,7 @@ namespace
u64 read_at(u64 offset, void* buffer, u64 size) override
{
return m_file.read_at(m_off + m_pos, buffer, std::min<u64>(size, utils::sub_saturate<u64>(m_max_size, m_pos)));
return m_file.read_at(offset + m_off, buffer, std::min<u64>(size, utils::sub_saturate<u64>(m_max_size, m_pos)));
}
u64 write(const void*, u64) override