* Top-level default leafs assigned.
* Enforcing RFC 7950 Sec 7.6.1 means unassigned top-level leafs (or leafs under non-presence containers) are assigned default values. * NACM default behaviour is read-only (empty configs are dead-lockedd) * This applies if NACM is loaded and `CLICON_NACM_MODE` is `internal` * Fixed: [default values don't show up in datastores #111](https://github.com/clicon/clixon/issues/111)
This commit is contained in:
parent
65733ffe69
commit
794d51a365
30 changed files with 593 additions and 167 deletions
|
|
@ -226,7 +226,7 @@ startup_extraxml(clicon_handle h,
|
|||
/* Clear tmp db */
|
||||
if (xmldb_db_reset(h, tmp_db) < 0)
|
||||
goto done;
|
||||
/* Application may define extra xml in its reset function*/
|
||||
/* Application may define extra xml in its reset function */
|
||||
if (clixon_plugin_reset_all(h, tmp_db) < 0)
|
||||
goto done;
|
||||
/* Extra XML can also be added via file */
|
||||
|
|
@ -238,13 +238,13 @@ startup_extraxml(clicon_handle h,
|
|||
goto fail;
|
||||
}
|
||||
/*
|
||||
* Check if tmp db is empty.
|
||||
* Check if tmp db is empty. XXX no this is not possible.
|
||||
* It should be empty if extra-xml is null and reset plugins did nothing
|
||||
* then skip validation.
|
||||
*/
|
||||
if (xmldb_get(h, tmp_db, NULL, NULL, &xt0) < 0)
|
||||
goto done;
|
||||
if (xt0==NULL || xml_child_nr(xt0)==0)
|
||||
if (xmldb_empty_get(h, tmp_db))
|
||||
goto ok;
|
||||
xt = NULL;
|
||||
/* Validate the tmp db and return possibly upgraded xml in xt
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue