Savestates/sys_fs: Utilize fs::file::get_id to fix an old bug

This commit is contained in:
Elad Ashkenazi 2023-07-17 07:28:27 +03:00
parent eecadab387
commit 41d38975f7

View file

@ -499,13 +499,10 @@ void lv2_file::save(utils::serial& ar)
return true;
}
fs::stat_t test_s = test.get_stat();
fs::stat_t file_s = file.get_stat();
fs::file_id test_s = test.get_id();
fs::file_id file_s = file.get_id();
// They don't matter for comparison and only create problems with encrypted files
test_s.is_writable = file_s.is_writable;
test_s.size = file_s.size;
return test_s != file_s;
return test_s.is_coherent_with(file_s);
}();
if (in_mem)