[xml_parse_string() is slow for a long XML string #96](https://github.com/clicon/clixon/issues/96)
This commit is contained in:
parent
6b9a9d46f9
commit
039e08f86a
7 changed files with 83 additions and 35 deletions
|
|
@ -451,7 +451,11 @@ clixon_xml_changelog_init(clicon_handle h)
|
|||
if (ret==1 && (ret = xml_yang_validate_add(h, xt, &xret)) < 0)
|
||||
goto done;
|
||||
if (ret == 0){ /* validation failed */
|
||||
if (netconf_err2cb(xret, &cbret) < 0)
|
||||
if ((cbret = cbuf_new()) ==NULL){
|
||||
clicon_err(OE_XML, errno, "cbuf_new");
|
||||
goto done;
|
||||
}
|
||||
if (netconf_err2cb(xret, cbret) < 0)
|
||||
goto done;
|
||||
clicon_err(OE_YANG, 0, "validation failed: %s", cbuf_get(cbret));
|
||||
goto done;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue