CHANGE updated for libyang changes
diff --git a/src/netopeerguid.c b/src/netopeerguid.c
index 26276ea..69b2f3c 100644
--- a/src/netopeerguid.c
+++ b/src/netopeerguid.c
@@ -572,7 +572,7 @@
static void
node_metadata_ident_recursive(struct lys_ident *ident, json_object *array)
{
- struct lys_ident_der *cur;
+ int i;
json_object *obj;
if (!ident) {
@@ -582,8 +582,8 @@
obj = json_object_new_string(ident->name);
json_object_array_add(array, obj);
- for (cur = ident->der; cur; cur = cur->next) {
- node_metadata_ident_recursive(cur->ident, array);
+ for (i = 0; ident->der[i]; ++i) {
+ node_metadata_ident_recursive(ident->der[i], array);
}
}