xpath BUGFIX all node types must be in the hash table
Fixes sysrepo/sysrepo#2592
@@ -1211,10 +1211,9 @@ set_insert_node(struct lyxp_set *set, const struct lyd_node *node, uint32_t pos,
set->val.nodes[idx].pos = pos;
++set->used;
- if (set->val.nodes[idx].type == LYXP_NODE_ELEM) {
+ /* add into hash table */
set_insert_node_hash(set, (struct lyd_node *)node, node_type);
}
-}
LY_ERR
lyxp_set_scnode_insert_node(struct lyxp_set *set, const struct lysc_node *node, enum lyxp_node_type node_type, uint32_t *index_p)
