Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions Shared/mods/deathmatch/logic/luadefs/CLuaXMLDefs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ int CLuaXMLDefs::xmlLoadFile ( lua_State* luaVM )

// Grab our resource
CLuaMain* pLuaMain = m_pLuaManager->GetVirtualMachine ( luaVM );
SString strError = "";
if ( pLuaMain )
{
SString strFileInput;
Expand Down Expand Up @@ -184,6 +185,8 @@ int CLuaXMLDefs::xmlLoadFile ( lua_State* luaVM )
}
}

xmlFile->GetLastError ( strError );
argStream.SetCustomError(strError, SString("Unable to read XML file %s", strFileInput.c_str()));
// Destroy it if we failed
pLuaMain->DestroyXML ( xmlFile );
}
Expand Down