AP_Arming: correct compilation when AP_Vehicle not available

This commit is contained in:
Peter Barker 2023-12-12 23:10:17 +11:00 committed by Peter Barker
parent 70cc84dd89
commit 8ef98c0f41
1 changed files with 2 additions and 0 deletions

View File

@ -902,6 +902,7 @@ bool AP_Arming::mission_checks(bool report)
}
#endif
#if AP_VEHICLE_ENABLED
// do not allow arming if there are no mission items and we are in
// (e.g.) AUTO mode
if (AP::vehicle()->current_mode_requires_mission() &&
@ -909,6 +910,7 @@ bool AP_Arming::mission_checks(bool report)
check_failed(ARMING_CHECK_MISSION, report, "Mode requires mission");
return false;
}
#endif
return true;
}