cfg: fix config save atomicity (#760)

## Link to GitHub Issue or related Pull Request, if one exists
n/a

## Description of change
Fully flush `tmp` file and then use `MoveFileExW` instead of `CopyFileW`
which guarantees atomic operation on NTFS.

## Testing
This commit is contained in:
bicarus
2026-06-15 02:06:04 -07:00
committed by GitHub
parent 6fec169347
commit ac51acdafe
4 changed files with 42 additions and 16 deletions
+1 -1
View File
@@ -536,7 +536,7 @@ namespace overlay::windows {
}
void CardManager::config_save() {
log_info("cardmanager", "saving config");
log_misc("cardmanager", "saving config...");
// create document
Document doc;