xpath CHANGE move to YANG 1.1 accessible trees
Now there are only 2 kinds of roots and accessible trees.
Also some minor optimizations and a small bugfix included.
diff --git a/src/resolve.c b/src/resolve.c
index 9bd5388..0f7c9db 100644
--- a/src/resolve.c
+++ b/src/resolve.c
@@ -4989,10 +4989,10 @@
if (schema->flags & LYS_CONFIG_W) {
*ctx_snode_type = LYXP_NODE_ROOT_CONFIG;
} else {
- *ctx_snode_type = LYXP_NODE_ROOT_STATE;
+ *ctx_snode_type = LYXP_NODE_ROOT;
}
/* we need the first top-level sibling, but no uses or groupings */
- schema = lys_getnext(NULL, NULL, lys_node_module(schema), LYS_GETNEXT_WITHCHOICE);
+ schema = lys_getnext(NULL, NULL, lys_node_module(schema), 0);
break;
}
schema = sparent;