1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-07-20 19:44:05 +00:00

Print error code when failed to open file on Windows

This commit is contained in:
Andrei Kortunov 2020-01-01 12:35:17 +04:00
parent 5a17d8e5a4
commit 75fed1d236

View file

@ -261,7 +261,7 @@ void LowLevelFile::open (char const * filename)
if (handle == INVALID_HANDLE_VALUE) if (handle == INVALID_HANDLE_VALUE)
{ {
std::ostringstream os; std::ostringstream os;
os << "Failed to open '" << filename << "' for reading."; os << "Failed to open '" << filename << "' for reading: " << GetLastError();
throw std::runtime_error (os.str ()); throw std::runtime_error (os.str ());
} }