Fix bug: Invalid calibration loaded if no calibration is present on sd card
This commit is contained in:
parent
44c861a245
commit
75f9c58c54
@ -136,7 +136,9 @@ int sd_card_settings_try_load_calibration(float *sens_deviation, float *offset)
|
||||
|
||||
get_controller_settings_path(path, sizeof(path), "calibration");
|
||||
p = config_parser_open_file(&parser, false, path, workbuff, sizeof(workbuff));
|
||||
status = 0;
|
||||
|
||||
if (!p)
|
||||
return status;
|
||||
do {
|
||||
res = config_parser_get_line(p, &entry, true);
|
||||
if (res == CONFIG_PARSER_OK) {
|
||||
|
Loading…
Reference in New Issue
Block a user