WTP reads two configs no

It read 1st the file startup.ckv, wich will
never be overwritten.
And then config.ckv, wich will saved when
ever config cahnges ar made.
This commit is contained in:
2022-08-27 10:16:49 +02:00
parent d7c826fac6
commit 4995cac9b8
4 changed files with 34 additions and 10 deletions

View File

@ -35,7 +35,7 @@ static int update_cb(struct cw_ElemHandlerParams * params, uint8_t * elems_ptr,
// cw_dbg(DBG_X," **** Configuration Update Request Received ***");
// cw_cfg_dump(params->conn->global_cfg);
cw_cfg_copy(params->cfg, params->conn->global_cfg,DBG_CFG_UPDATES,"GlobalCfg");
cw_cfg_save(bootcfg.cfgfilename, params->conn->global_cfg,
cw_cfg_save(bootcfg.config_file, params->conn->global_cfg,
"#\n# This file is igenerated by WAT\n# If you edit this, your cahnges might be overwritten\n#\n");
// cw_dbg(DBG_X," **** Configuration Update Request Received Saved ***");
return 0;