Added sanity check for an action pointer
This commit is contained in:
committed by
Chris Hennes
parent
9ada83aebd
commit
cab9053be8
@@ -153,7 +153,9 @@ long NavlibInterface::SetActiveCommand(std::string commandId)
|
||||
if (!std::string(command->getName()).compare(parsedData.commandName)) {
|
||||
if (parsedData.actionIndex == -1) {
|
||||
Gui::Action* pAction = command->getAction();
|
||||
pAction->action()->trigger();
|
||||
if (pAction != nullptr) {
|
||||
pAction->action()->trigger();
|
||||
}
|
||||
}
|
||||
else
|
||||
command->invoke(parsedData.actionIndex);
|
||||
|
||||
Reference in New Issue
Block a user