]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Fixes error message in 'show route' cmd.
authorOndrej Zajicek <santiago@crfreenet.org>
Sat, 8 Nov 2014 22:52:42 +0000 (23:52 +0100)
committerOndrej Zajicek <santiago@crfreenet.org>
Sat, 8 Nov 2014 22:52:42 +0000 (23:52 +0100)
Message 'Network not in table' was not reported if a network node without
any routes was found in a routing table.

nest/rt-table.c

index 59fd07116685291999e55b0a2c4301e1c2b04ad2..125f1d18eb64a20b18aef3c8e3b41543ecfa3f76 100644 (file)
@@ -2409,11 +2409,12 @@ rt_show(struct rt_show_data *d)
        n = net_route(d->table, d->prefix, d->pxlen);
       else
        n = net_find(d->table, d->prefix, d->pxlen);
+
       if (n)
-       {
-         rt_show_net(this_cli, n, d);
-         cli_msg(0, "");
-       }
+       rt_show_net(this_cli, n, d);
+
+      if (d->rt_counter)
+       cli_msg(0, "");
       else
        cli_msg(8001, "Network not in table");
     }