summaryrefslogtreecommitdiffstats
path: root/tests/lib/test_nexthop_iter.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lib/test_nexthop_iter.c')
-rw-r--r--tests/lib/test_nexthop_iter.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/tests/lib/test_nexthop_iter.c b/tests/lib/test_nexthop_iter.c
index 77515386c..6c8ffb8da 100644
--- a/tests/lib/test_nexthop_iter.c
+++ b/tests/lib/test_nexthop_iter.c
@@ -173,13 +173,12 @@ nexthop_chain_free(struct nexthop_chain *nc)
static void
nexthop_chain_verify_iter(struct nexthop_chain *nc)
{
- struct nexthop *nh, *tnh;
- int recursing;
+ struct nexthop *nh;
char *repr = NULL;
- for (ALL_NEXTHOPS_RO(nc->head, nh, tnh, recursing))
+ for (ALL_NEXTHOPS_RO(nc->head, nh))
{
- if (recursing)
+ if (nh->rparent)
str_appendf(&repr, " %p\n", nh);
else
str_appendf(&repr, "%p\n", nh);