Browse Source

gps: Increase param name buffer to address warning in newer gccs (#19876)

main
Thomas Debrunner 3 years ago committed by GitHub
parent
commit
42c562b748
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      src/drivers/gps/gps.cpp

2
src/drivers/gps/gps.cpp

@ -325,7 +325,7 @@ GPS::GPS(const char *path, gps_driver_mode_t mode, GPSHelper::Interface interfac @@ -325,7 +325,7 @@ GPS::GPS(const char *path, gps_driver_mode_t mode, GPSHelper::Interface interfac
if (_mode == gps_driver_mode_t::None) {
// use parameter to select mode if not provided via CLI
char protocol_param_name[16];
char protocol_param_name[17];
snprintf(protocol_param_name, sizeof(protocol_param_name), "GPS_%i_PROTOCOL", (int)_instance + 1);
int32_t protocol = 0;
param_get(param_find(protocol_param_name), &protocol);

Loading…
Cancel
Save