From a5144a78fc4dd61f90d1534d24057ad07978b5ac Mon Sep 17 00:00:00 2001 From: SulfurNitride Date: Fri, 19 Jun 2026 22:39:25 -0500 Subject: Revert "Disable VFS cache for writable handles" This reverts commit 41a336cc8e53ba062ab791ffd6dc9b90d2c72899. --- src/src/vfs/mo2filesystem.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/src/vfs/mo2filesystem.cpp b/src/src/vfs/mo2filesystem.cpp index d23c2e6..5176614 100644 --- a/src/src/vfs/mo2filesystem.cpp +++ b/src/src/vfs/mo2filesystem.cpp @@ -1930,11 +1930,7 @@ void mo2_open(fuse_req_t req, fuse_ino_t ino, struct fuse_file_info* fi) } fi->fh = fh; - // Read-only mod/game files are immutable during a session, so keeping the - // page cache is safe and fast. Writable handles can remap the same VFS inode - // from a mod file to a staged copy, and repeated INI API calls need to read - // the just-written staged content rather than stale cached pages. - fi->keep_cache = writable ? 0 : 1; + fi->keep_cache = 1; fuse_reply_open(req, fi); } @@ -2219,7 +2215,7 @@ void mo2_create(fuse_req_t req, fuse_ino_t parent, const char* name, mode_t mode } fi->fh = fh; - fi->keep_cache = 0; + fi->keep_cache = 1; struct fuse_entry_param e; std::memset(&e, 0, sizeof(e)); -- cgit v1.3.1