fix(ekf2): free the system flag buffer in the destructor (#29483)

_system_flag_buffer is allocated on first use like the sensor buffers,
but it was the only one the destructor did not delete, so every
`ekf2 stop` leaked it.

Reported by @lihnucs.

Assisted-by: Claude:claude-opus-5-5

Signed-off-by: Julian Oes <julian@oes.ch>
(cherry picked from commit cb61f8c4f1)
This commit is contained in:
Julian Oes committed 2026-10-30 15:17:00 +01:00
1 parent afb09f3b1c
commit 68e844c46b
1 file changed
+2
@@ -76,6 +76,8 @@ EstimatorInterface::~EstimatorInterface()
#if defined(CONFIG_EKF2_RANGING_BEACON)
delete _ranging_beacon_buffer;
#endif // CONFIG_EKF2_RANGING_BEACON
delete _system_flag_buffer;
}
// Accumulate imu data and store to buffer at desired rate