mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-06-26 05:30:35 +08:00
MAVLink app: Zero-initialize whole struct
This commit is contained in:
@@ -977,7 +977,7 @@ protected:
|
||||
struct vehicle_gps_position_s gps;
|
||||
|
||||
if (_gps_sub->update(&_gps_time, &gps)) {
|
||||
mavlink_gps_raw_int_t msg;
|
||||
mavlink_gps_raw_int_t msg = {};
|
||||
|
||||
msg.time_usec = gps.timestamp_position;
|
||||
msg.fix_type = gps.fix_type;
|
||||
|
||||
Reference in New Issue
Block a user