AP_NavEKF2: fixed build with g++ 9.1

this is a false positive, but the cost of clearing this array is low,
and it saves a much more complex fix
This commit is contained in:
Andrew Tridgell 2019-09-24 14:58:56 +10:00
parent abae134f53
commit d40d812ea4
2 changed files with 2 additions and 2 deletions

View File

@ -1040,7 +1040,7 @@ void NavEKF2_core::FuseDeclination(float declErr)
float t12 = 1.0f/t11;
float H_MAG[24];
Vector28 Kfusion;
Vector28 Kfusion {};
H_MAG[16] = -magE*t5;
H_MAG[17] = magN*t5;

View File

@ -285,7 +285,7 @@ void NavEKF2_core::FuseOptFlow()
Vector3f relVelSensor;
Vector14 SH_LOS;
Vector2 losPred;
Vector28 Kfusion;
Vector28 Kfusion {};
// Copy required states to local variable names
float q0 = stateStruct.quat[0];