Don't count networks with no routes (they are not displayed at all and
will be removed during the next garbage collection pass).
This commit is contained in:
parent
23693958aa
commit
0d3070824d
1 changed files with 2 additions and 1 deletions
|
@ -720,6 +720,7 @@ rt_show_net(struct cli *c, net *n, struct rt_show_data *d)
|
||||||
int ok;
|
int ok;
|
||||||
|
|
||||||
bsprintf(ia, "%I/%d", n->n.prefix, n->n.pxlen);
|
bsprintf(ia, "%I/%d", n->n.prefix, n->n.pxlen);
|
||||||
|
if (n->routes)
|
||||||
d->net_counter++;
|
d->net_counter++;
|
||||||
for(e=n->routes; e; e=e->next)
|
for(e=n->routes; e; e=e->next)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue