From a0d32d493c0781dc283106d418542f995a493a8c Mon Sep 17 00:00:00 2001 From: refractionpcsx2 Date: Fri, 14 Jun 2024 21:32:23 +0100 Subject: [PATCH] CDVD: Correct NVM file saving to be in write mode --- pcsx2/CDVD/CDVD.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pcsx2/CDVD/CDVD.cpp b/pcsx2/CDVD/CDVD.cpp index b2e4df7caf..049a7b904e 100644 --- a/pcsx2/CDVD/CDVD.cpp +++ b/pcsx2/CDVD/CDVD.cpp @@ -197,7 +197,7 @@ void cdvdSaveNVRAM() { Error error; const std::string nvmfile = cdvdGetNVRAMPath(); - auto fp = FileSystem::OpenManagedCFile(nvmfile.c_str(), "r+b", &error); + auto fp = FileSystem::OpenManagedCFile(nvmfile.c_str(), "wb", &error); if (!fp) { ERROR_LOG("Failed to open NVRAM at {} for updating: {}", Path::GetFileName(nvmfile), error.GetDescription());