From 16b1bd8b9a81dbd538b6fcd60a56c99a56f63670 Mon Sep 17 00:00:00 2001 From: Iampete1 Date: Mon, 30 Jan 2023 18:13:09 +0000 Subject: [PATCH] AP_NavEKF3: pre-arm return failure message for correct core --- libraries/AP_NavEKF3/AP_NavEKF3.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/AP_NavEKF3/AP_NavEKF3.cpp b/libraries/AP_NavEKF3/AP_NavEKF3.cpp index 1b285e12ff..153f6c5421 100644 --- a/libraries/AP_NavEKF3/AP_NavEKF3.cpp +++ b/libraries/AP_NavEKF3/AP_NavEKF3.cpp @@ -1136,7 +1136,7 @@ bool NavEKF3::pre_arm_check(bool requires_position, char *failure_msg, uint8_t f } for (uint8_t i = 0; i < num_cores; i++) { if (!core[i].healthy()) { - const char *failure = core[primary].prearm_failure_reason(); + const char *failure = core[i].prearm_failure_reason(); if (failure != nullptr) { AP::dal().snprintf(failure_msg, failure_msg_len, failure); } else {