mirror of https://github.com/ArduPilot/ardupilot
Rover: Initialize a string array
This commit is contained in:
parent
501bd61820
commit
65cfded501
|
@ -157,7 +157,7 @@ bool AP_Arming_Rover::disarm(const AP_Arming::Method method, bool do_disarm_chec
|
|||
// check object avoidance has initialised correctly
|
||||
bool AP_Arming_Rover::oa_check(bool report)
|
||||
{
|
||||
char failure_msg[50];
|
||||
char failure_msg[50] = {};
|
||||
if (rover.g2.oa.pre_arm_check(failure_msg, ARRAY_SIZE(failure_msg))) {
|
||||
return true;
|
||||
}
|
||||
|
@ -205,7 +205,7 @@ bool AP_Arming_Rover::motor_checks(bool report)
|
|||
bool ret = rover.g2.motors.pre_arm_check(report);
|
||||
|
||||
#if HAL_TORQEEDO_ENABLED
|
||||
char failure_msg[50];
|
||||
char failure_msg[50] = {};
|
||||
AP_Torqeedo *torqeedo = AP_Torqeedo::get_singleton();
|
||||
if (torqeedo != nullptr) {
|
||||
if (!torqeedo->pre_arm_checks(failure_msg, ARRAY_SIZE(failure_msg))) {
|
||||
|
|
Loading…
Reference in New Issue