mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-04-28 13:28:01 +03:00
fs::file: always use strict reading mode for large reads (#11206)
This commit is contained in:
parent
f910a152f1
commit
f16949c292
8 changed files with 55 additions and 69 deletions
|
@ -1658,7 +1658,7 @@ bool fs::dir::open(const std::string& path)
|
|||
|
||||
bool fs::file::strict_read_check(u64 _size, u64 type_size) const
|
||||
{
|
||||
if (usz pos0 = pos(), size0 = size(); pos0 >= size0 || (size0 - pos0) / type_size < _size)
|
||||
if (usz pos0 = pos(), size0 = size(); (pos0 >= size0 ? 0 : (size0 - pos0)) / type_size < _size)
|
||||
{
|
||||
fs::g_tls_error = fs::error::inval;
|
||||
return false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue