schema tree FEATURE leafrefs can reference leaf-lists as well
diff --git a/src/tree_schema.c b/src/tree_schema.c
index 3054616..0b1f4b1 100644
--- a/src/tree_schema.c
+++ b/src/tree_schema.c
@@ -2954,7 +2954,7 @@
{
struct lys_node_leaf *iter = leafref_target;
- if (leafref_target->nodetype != LYS_LEAF) {
+ if (!(leafref_target->nodetype & (LYS_LEAF | LYS_LEAFLIST))) {
LOGINT;
return -1;
}
@@ -2970,7 +2970,7 @@
}
/* create fake child - the ly_set structure to hold the list of
- * leafrefs referencing the leaf */
+ * leafrefs referencing the leaf(-list) */
if (!leafref_target->child) {
leafref_target->child = (void*)ly_set_new();
if (!leafref_target->child) {