ArduCopter: use fence singleton in afs check

This commit is contained in:
Peter Barker 2022-10-21 12:25:52 +11:00 committed by Andrew Tridgell
parent ad0df546a7
commit 7ed190c163
1 changed files with 1 additions and 6 deletions

View File

@ -79,11 +79,6 @@ void Copter::failsafe_check()
void Copter::afs_fs_check(void)
{
// perform AFS failsafe checks
#if AP_FENCE_ENABLED
const bool fence_breached = fence.get_breaches() != 0;
#else
const bool fence_breached = false;
#endif
g2.afs.check(fence_breached, last_radio_update_ms);
g2.afs.check(last_radio_update_ms);
}
#endif