* Changed debug levels in clicon_debug() to be based on maskable flags
* Added flag names: `CLIXON_DBG_*`
* Added maskable flags that can be combined when debugging:
* `DEFAULT` = 1: Basic debug message, espcially initialization
* `MSG` = 2: Input and output packets, read datastore
* `DETAIL` = 4: Details: message dump in hex, xpath parse trees, etc
* `EXTRA` = 8: Extra detailed logs
* Test: some errors in yang-lib where content-id was in wrong place
This commit is contained in:
parent
8342b74968
commit
da9bfcbb53
47 changed files with 425 additions and 210 deletions
|
|
@ -183,7 +183,7 @@ json_current_new(clixon_json_yacc *jy,
|
|||
char *prefix = NULL;
|
||||
char *id = NULL;
|
||||
|
||||
clicon_debug(2, "%s", __FUNCTION__);
|
||||
clicon_debug(CLIXON_DBG_DETAIL, "%s", __FUNCTION__);
|
||||
/* Find colon separator and if found split into prefix:name */
|
||||
if (nodeid_split(name, &prefix, &id) < 0)
|
||||
goto done;
|
||||
|
|
@ -210,7 +210,7 @@ json_current_new(clixon_json_yacc *jy,
|
|||
static int
|
||||
json_current_pop(clixon_json_yacc *jy)
|
||||
{
|
||||
clicon_debug(2, "%s", __FUNCTION__);
|
||||
clicon_debug(CLIXON_DBG_DETAIL, "%s", __FUNCTION__);
|
||||
if (jy->jy_current)
|
||||
jy->jy_current = xml_parent(jy->jy_current);
|
||||
return 0;
|
||||
|
|
@ -221,7 +221,7 @@ json_current_clone(clixon_json_yacc *jy)
|
|||
{
|
||||
cxobj *xn;
|
||||
|
||||
clicon_debug(2, "%s", __FUNCTION__);
|
||||
clicon_debug(CLIXON_DBG_DETAIL, "%s", __FUNCTION__);
|
||||
if (jy->jy_current == NULL){
|
||||
return -1;
|
||||
}
|
||||
|
|
@ -254,7 +254,7 @@ json_current_body(clixon_json_yacc *jy,
|
|||
int retval = -1;
|
||||
cxobj *xn;
|
||||
|
||||
clicon_debug(2, "%s", __FUNCTION__);
|
||||
clicon_debug(CLIXON_DBG_DETAIL, "%s", __FUNCTION__);
|
||||
if ((xn = xml_new("body", jy->jy_current, CX_BODY)) == NULL)
|
||||
goto done;
|
||||
if (value && xml_value_append(xn, value) < 0)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue