]> git.puffer.fish Git - mirror/frr.git/commitdiff
zebra: do not hide distance and metric for kernel routes
authorJorge Boncompte <jbonor@gmail.com>
Tue, 25 Jul 2017 11:24:09 +0000 (13:24 +0200)
committerJorge Boncompte <jbonor@gmail.com>
Fri, 4 Aug 2017 08:19:36 +0000 (10:19 +0200)
There's no reason for not showing this information.

Signed-off-by: Jorge Boncompte <jbonor@gmail.com>
zebra/zebra_vty.c

index 184e1dc36779ac5d12bee34b9bdde17fb129badb..13c4429d6a60733538aa2b976e62bb2acdab45a2 100644 (file)
@@ -589,8 +589,7 @@ static void vty_show_ip_route(struct vty *vty, struct route_node *rn,
                if (CHECK_FLAG(re->flags, ZEBRA_FLAG_SELECTED))
                        json_object_boolean_true_add(json_route, "selected");
 
-               if (re->type != ZEBRA_ROUTE_CONNECT
-                   && re->type != ZEBRA_ROUTE_KERNEL) {
+               if (re->type != ZEBRA_ROUTE_CONNECT) {
                        json_object_int_add(json_route, "distance",
                                            re->distance);
                        json_object_int_add(json_route, "metric", re->metric);
@@ -777,8 +776,7 @@ static void vty_show_ip_route(struct vty *vty, struct route_node *rn,
                                srcdest_rnode2str(rn, buf, sizeof buf));
 
                        /* Distance and metric display. */
-                       if (re->type != ZEBRA_ROUTE_CONNECT
-                           && re->type != ZEBRA_ROUTE_KERNEL)
+                       if (re->type != ZEBRA_ROUTE_CONNECT)
                                len += vty_out(vty, " [%d/%d]", re->distance,
                                               re->metric);
                } else