Skip to content

Commit 4bef7e2

Browse files
committed
Fix DataModule::ReadModuleProperties failing when trying to read index of module in Mods/ directory
Reader gets the full path from passed in filepath but doesn't actually use it for the fail check
1 parent db30fbb commit 4bef7e2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

System/Reader.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,8 @@ namespace RTE {
4949

5050
m_CanFail = failOK;
5151

52-
m_Stream = std::make_unique<std::ifstream>(fileName);
53-
if (!m_CanFail) { RTEAssert(System::PathExistsCaseSensitive(fileName) && m_Stream->good(), "Failed to open data file \"" + m_FilePath + "\"!"); }
52+
m_Stream = std::make_unique<std::ifstream>(m_FilePath);
53+
if (!m_CanFail) { RTEAssert(System::PathExistsCaseSensitive(m_FilePath) && m_Stream->good(), "Failed to open data file \"" + m_FilePath + "\"!"); }
5454

5555
m_OverwriteExisting = overwrites;
5656

0 commit comments

Comments
 (0)