From 6d2c857db92a8bfc15f12a55e5fe8aaf51457489 Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Sat, 9 Dec 2023 15:09:55 +1100 Subject: [PATCH] AP_Arming: correct compilation when AP_MISSION_ENABLED is false --- libraries/AP_Arming/AP_Arming.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libraries/AP_Arming/AP_Arming.cpp b/libraries/AP_Arming/AP_Arming.cpp index 6a8bae36cc..209dbdefe1 100644 --- a/libraries/AP_Arming/AP_Arming.cpp +++ b/libraries/AP_Arming/AP_Arming.cpp @@ -1125,6 +1125,7 @@ bool AP_Arming::system_checks(bool report) bool AP_Arming::terrain_database_required() const { +#if AP_MISSION_ENABLED AP_Mission *mission = AP::mission(); if (mission == nullptr) { // no mission support? @@ -1133,6 +1134,7 @@ bool AP_Arming::terrain_database_required() const if (mission->contains_terrain_alt_items()) { return true; } +#endif return false; }