Tracker: correct compilation when AP_AdvancedFailsafe is disabled

This commit is contained in:
Peter Barker 2023-02-20 09:48:39 +11:00 committed by Peter Barker
parent 5a4fee6ac3
commit 627b9b3034
1 changed files with 2 additions and 0 deletions

View File

@ -247,9 +247,11 @@ bool Tracker::should_log(uint32_t mask)
#include <AP_Avoidance/AP_Avoidance.h>
#include <AP_ADSB/AP_ADSB.h>
#if AP_ADVANCEDFAILSAFE_ENABLED
// dummy method to avoid linking AFS
bool AP_AdvancedFailsafe::gcs_terminate(bool should_terminate, const char *reason) {return false;}
AP_AdvancedFailsafe *AP::advancedfailsafe() { return nullptr; }
#endif // AP_ADVANCEDFAILSAFE_ENABLED
#if HAL_ADSB_ENABLED
// dummy method to avoid linking AP_Avoidance
AP_Avoidance *AP::ap_avoidance() { return nullptr; }