Refactored YANG min/max validation code, created new clixon_validate_minmax.[ch]
Added new recursive minmax check for non-presence containers This makes validation checks stricter, including check of incoming RPCs Renamed xml_yang_check_list_unique_minmax() to xml_yang_minmax_recurse() Fixed again: [YANG min-elements within non-presence container does not work](https://github.com/clicon/clixon/issues/355)
This commit is contained in:
parent
c8bf718db8
commit
2eb9c6cda1
17 changed files with 867 additions and 614 deletions
|
|
@ -1165,7 +1165,10 @@ xmldb_get0_clear(clicon_handle h,
|
|||
/* Remove global defaults and empty non-presence containers */
|
||||
if (xml_defaults_nopresence(x, 1) < 0)
|
||||
goto done;
|
||||
/* clear flags: mark and change */
|
||||
/* Clear XML tree of defaults */
|
||||
if (xml_tree_prune_flagged(x, XML_FLAG_TRANSIENT, 1) < 0)
|
||||
goto done;
|
||||
/* clear mark and change */
|
||||
xml_apply0(x, CX_ELMNT, (xml_applyfn_t*)xml_flag_reset,
|
||||
(void*)(XML_FLAG_MARK|XML_FLAG_ADD|XML_FLAG_CHANGE));
|
||||
ok:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue