d/wmr: Rename wmr_config_parse to wmr_hmd_config_parse()

This commit is contained in:
Jan Schmidt 2021-12-03 04:20:20 +11:00
parent bb5aa35c00
commit 76c18bfdc7
3 changed files with 5 additions and 5 deletions

View file

@ -29,7 +29,7 @@
#define JSON_STRING(a, b, c) u_json_get_string_into_array(u_json_get(a, b), c, sizeof(c))
static void
wmr_config_init_defaults(struct wmr_hmd_config *c)
wmr_hmd_config_init_defaults(struct wmr_hmd_config *c)
{
memset(c, 0, sizeof(struct wmr_hmd_config));
@ -383,9 +383,9 @@ wmr_config_parse_calibration(struct wmr_hmd_config *c, cJSON *calib_info, enum u
bool
wmr_config_parse(struct wmr_hmd_config *c, char *json_string, enum u_logging_level log_level)
wmr_hmd_config_parse(struct wmr_hmd_config *c, char *json_string, enum u_logging_level log_level)
{
wmr_config_init_defaults(c);
wmr_hmd_config_init_defaults(c);
cJSON *json_root = cJSON_Parse(json_string);
if (!cJSON_IsObject(json_root)) {

View file

@ -119,7 +119,7 @@ struct wmr_hmd_config
};
bool
wmr_config_parse(struct wmr_hmd_config *c, char *json_string, enum u_logging_level log_level);
wmr_hmd_config_parse(struct wmr_hmd_config *c, char *json_string, enum u_logging_level log_level);
struct wmr_bt_controller_config

View file

@ -645,7 +645,7 @@ wmr_read_config(struct wmr_hmd *wh)
config_json_block[i] ^= wmr_config_key[i % sizeof(wmr_config_key)];
}
if (!wmr_config_parse(&wh->config, (char *)config_json_block, wh->log_level)) {
if (!wmr_hmd_config_parse(&wh->config, (char *)config_json_block, wh->log_level)) {
free(data);
return -1;
}