tree CHANGE test for NULL in LY_ARRAY_COUNT() macro

Make it more safe in cost of losing possibility to use macro as lvalue.
diff --git a/src/schema_features.c b/src/schema_features.c
index 16ccaed..15ffed9 100644
--- a/src/schema_features.c
+++ b/src/schema_features.c
@@ -105,7 +105,7 @@
     if (!*idx) {
         /* module features */
         features = pmod->features;
-    } else if (pmod->includes && ((*idx - 1) < LY_ARRAY_COUNT(pmod->includes))) {
+    } else if ((*idx - 1) < LY_ARRAY_COUNT(pmod->includes)) {
         /* submodule features */
         features = pmod->includes[*idx - 1].submodule->features;
     } else {
@@ -647,9 +647,6 @@
 
     for (v = 0; v < recursion.count; ++v) {
         drv = recursion.objs[v];
-        if (!drv->depfeatures) {
-            continue;
-        }
         for (u = 0; u < LY_ARRAY_COUNT(drv->depfeatures); ++u) {
             if (feature == drv->depfeatures[u]) {
                 LOGVAL(ctx, LY_VLOG_NONE, NULL, LYVE_REFERENCE, "Feature \"%s\" is indirectly referenced from itself.",