mirror of
https://github.com/AquariaOSE/Aquaria.git
synced 2025-02-09 21:34:01 +00:00
fix possible startup crash
This commit is contained in:
parent
ffa26e4105
commit
d84a8bb2c2
1 changed files with 2 additions and 4 deletions
|
@ -482,12 +482,10 @@ void UserSettings::load(bool doApply, const std::string &overrideFile)
|
||||||
xml_action = xml_actionSet->FirstChildElement();
|
xml_action = xml_actionSet->FirstChildElement();
|
||||||
while (xml_action)
|
while (xml_action)
|
||||||
{
|
{
|
||||||
std::string name = xml_action->Attribute("name");
|
const char *name = xml_action->Attribute("name");
|
||||||
|
if (name && *name)
|
||||||
if (!name.empty())
|
|
||||||
{
|
{
|
||||||
ActionInput *ai = control.actionSet.addActionInput(name);
|
ActionInput *ai = control.actionSet.addActionInput(name);
|
||||||
|
|
||||||
ai->fromString(xml_action->Attribute("input"));
|
ai->fromString(xml_action->Attribute("input"));
|
||||||
}
|
}
|
||||||
xml_action = xml_action->NextSiblingElement();
|
xml_action = xml_action->NextSiblingElement();
|
||||||
|
|
Loading…
Add table
Reference in a new issue