* Full support of XPATH 1.0 according to https://www.w3.org/TR/xpath-10 using yacc/lex

* The previous XPATH imlementation was very restricted.
  * The only function implemented is the Yang extension "current()". No other functions are implemented (eg last(), count()).
This commit is contained in:
Olof hagsand 2018-07-16 16:13:31 +02:00
parent 60ce7b12bd
commit bf728b37b8
26 changed files with 2856 additions and 481 deletions

View file

@ -436,7 +436,7 @@ db_regexp(char *file,
goto quit;
}
pair = &newpairs[npairs];
memset (pair, 0, sizeof(*pair));
memset(pair, 0, sizeof(*pair));
pair->dp_key = chunk_sprintf(label, "%s", key);
if (regexp)
@ -451,7 +451,7 @@ db_regexp(char *file,
}
if ( ! noval) {
if (vlen){
pair->dp_val = chunkdup (val, vlen, label);
pair->dp_val = chunkdup(val, vlen, label);
if (pair->dp_val == NULL) {
clicon_err(OE_DB, errno, "%s: chunkdup", __FUNCTION__);
goto quit;