validation BUGFIX proper schema traversal

Fixes #611
diff --git a/src/validation.c b/src/validation.c
index a349ec8..3c9a29a 100644
--- a/src/validation.c
+++ b/src/validation.c
@@ -676,7 +676,8 @@
     }
 
     if (schema->nodetype & (LYS_LIST | LYS_CONTAINER | LYS_NOTIF | LYS_RPC | LYS_ACTION)) {
-        LY_TREE_FOR(schema->child, siter) {
+        siter = NULL;
+        while ((siter = lys_getnext(siter, schema, NULL, 0))) {
             if (siter->nodetype & (LYS_LIST | LYS_LEAFLIST)) {
                 LY_TREE_FOR(node->child, diter) {
                     if (diter->schema == siter && (diter->validity & LYD_VAL_UNIQUE)) {