System-only-config

* Fix startup diff
* Add system-only to running on startup
* JSON support:
This commit is contained in:
Olof hagsand 2024-10-16 13:46:47 +02:00
parent 3a656fac07
commit 69b65ad13d
19 changed files with 276 additions and 105 deletions

View file

@ -308,14 +308,14 @@ api_return_err(clixon_handle h,
clixon_debug(CLIXON_DBG_RESTCONF, "code:%d", code);
if (pretty){
cprintf(cb, "{\n\"ietf-restconf:errors\" : ");
if (clixon_json2cbuf(cb, xerr, pretty, 0, 0) < 0)
if (clixon_json2cbuf(cb, xerr, pretty, 0, 0, 0) < 0)
goto done;
cprintf(cb, "\n}\r\n");
}
else{
cprintf(cb, "{");
cprintf(cb, "\"ietf-restconf:errors\":");
if (clixon_json2cbuf(cb, xerr, pretty, 0, 0) < 0)
if (clixon_json2cbuf(cb, xerr, pretty, 0, 0, 0) < 0)
goto done;
cprintf(cb, "}\r\n");
}