From 259a1bcbb129e7e95f33d27434e979fbd2a8952f Mon Sep 17 00:00:00 2001 From: DoinLakeFlyer Date: Tue, 24 Mar 2020 20:01:03 -0700 Subject: [PATCH] Guard against UI Info not available causing crash --- src/MissionManager/SimpleMissionItem.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/MissionManager/SimpleMissionItem.cc b/src/MissionManager/SimpleMissionItem.cc index b22974d54..41ca2c67c 100644 --- a/src/MissionManager/SimpleMissionItem.cc +++ b/src/MissionManager/SimpleMissionItem.cc @@ -748,7 +748,7 @@ void SimpleMissionItem::_setDefaultsForCommand(void) // We default all acceptance radius to 0. This allows flight controller to be in control of // accept radius. _missionItem.setParam2(0); - } else if (uiInfo->isLandCommand() || command == MAV_CMD_DO_SET_ROI_LOCATION) { + } else if ((uiInfo && uiInfo->isLandCommand()) || command == MAV_CMD_DO_SET_ROI_LOCATION) { _altitudeFact.setRawValue(0); _missionItem.setParam7(0); } -- GitLab