diff --git a/include/Nazara/Core/Enums.hpp b/include/Nazara/Core/Enums.hpp index 270815087..765505575 100644 --- a/include/Nazara/Core/Enums.hpp +++ b/include/Nazara/Core/Enums.hpp @@ -81,7 +81,7 @@ namespace Nz OpenMode_Append, // Disable writing on existing parts and put the cursor at the end OpenMode_Lock, // Disable modifying the file before it is open - OpenMode_MustExit, // Fail if the file doesn't exists, even if opened in write mode + OpenMode_MustExist, // Fail if the file doesn't exists, even if opened in write mode OpenMode_ReadOnly, // Open in read only OpenMode_Text, // Open in text mod OpenMode_Truncate, // Create the file if it doesn't exist and empty it if it exists diff --git a/plugins/Assimp/CustomStream.cpp b/plugins/Assimp/CustomStream.cpp index 246e85ba5..6dbdd90b6 100644 --- a/plugins/Assimp/CustomStream.cpp +++ b/plugins/Assimp/CustomStream.cpp @@ -89,7 +89,7 @@ aiFile* StreamOpener(aiFileIO* fileIO, const char* filePath, const char* openMod { openModeEnum |= OpenMode_ReadOnly; if (std::strchr(openMode, '+')) - openModeEnum |= OpenMode_ReadWrite | OpenMode_MustExit; + openModeEnum |= OpenMode_ReadWrite | OpenMode_MustExist; } else if (std::strchr(openMode, 'w')) { diff --git a/src/Nazara/Core/Win32/FileImpl.cpp b/src/Nazara/Core/Win32/FileImpl.cpp index 709642e03..1fb5a19eb 100644 --- a/src/Nazara/Core/Win32/FileImpl.cpp +++ b/src/Nazara/Core/Win32/FileImpl.cpp @@ -65,7 +65,7 @@ namespace Nz { access |= GENERIC_READ; - if (mode & OpenMode_MustExit || (mode & OpenMode_WriteOnly) == 0) + if (mode & OpenMode_MustExist || (mode & OpenMode_WriteOnly) == 0) openMode |= OPEN_EXISTING; } @@ -78,7 +78,7 @@ namespace Nz if (mode & OpenMode_Truncate) openMode |= CREATE_ALWAYS; - else if (mode & OpenMode_MustExit) + else if (mode & OpenMode_MustExist) openMode |= OPEN_EXISTING; else openMode |= OPEN_ALWAYS;