[IO]: Forgot to return -1 on func failure (#866)
This commit is contained in:
parent
a52337bbac
commit
5766ecef1f
@ -20,6 +20,7 @@ namespace Components::GSC
|
|||||||
if (std::strstr(filepath, ForbiddenStrings[i]) != nullptr)
|
if (std::strstr(filepath, ForbiddenStrings[i]) != nullptr)
|
||||||
{
|
{
|
||||||
Logger::PrintError(Game::CON_CHANNEL_PARSERSCRIPT, "OpenFile: directory traversal is not allowed!\n");
|
Logger::PrintError(Game::CON_CHANNEL_PARSERSCRIPT, "OpenFile: directory traversal is not allowed!\n");
|
||||||
|
Game::Scr_AddInt(-1);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user