When determining whether to set the nhg_hash_entry as
invalid, we should have been checking the depends, not
the dependents. If its a group and at least one of its
depends is valid, the group is still valid.
Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
struct nhg_connected *rb_node_dep = NULL;
/* If anthing else in the group is valid, the group is valid */
- frr_each(nhg_connected_tree, &nhe->nhg_dependents,
- rb_node_dep) {
+ frr_each(nhg_connected_tree, &nhe->nhg_depends, rb_node_dep) {
if (CHECK_FLAG(rb_node_dep->nhe->flags,
NEXTHOP_GROUP_VALID))
return;