mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-09 16:35:13 +00:00
fs: alternative fs::pending_file implementation (Win32)
Use MOVEFILE_WRITE_THROUGH instead of sync() on commit().
This commit is contained in:
parent
aaa20c0ff0
commit
3c614d95b8
3 changed files with 21 additions and 1 deletions
|
|
@ -1946,7 +1946,9 @@ static NEVER_INLINE error_code savedata_op(ppu_thread& ppu, u32 operation, u32 v
|
|||
if (auto file = pair.second.release())
|
||||
{
|
||||
auto&& fvec = static_cast<fs::container_stream<std::vector<uchar>>&>(*file);
|
||||
ensure(fs::write_file<true>(new_path + vfs::escape(pair.first), fs::rewrite, fvec.obj));
|
||||
fs::pending_file f(new_path + vfs::escape(pair.first));
|
||||
f.file.write(fvec.obj);
|
||||
ensure(f.commit());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue