]> git.proxmox.com Git - mirror_frr.git/commitdiff
zebra: remove duplicated json information
authorPhilippe Guibert <philippe.guibert@6wind.com>
Mon, 25 Mar 2019 14:01:56 +0000 (15:01 +0100)
committerPhilippe Guibert <philippe.guibert@6wind.com>
Mon, 25 Mar 2019 14:02:52 +0000 (15:02 +0100)
the metric information is already present for connected routes. so
remove that line.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
zebra/zebra_vty.c

index b0884f22cfee050d6931814460ae3f4f823e88bf..82fbe68bfeac66a410681234ccacc020b1e3b0cd 100644 (file)
@@ -425,12 +425,6 @@ static void vty_show_ip_route(struct vty *vty, struct route_node *rn,
                if (CHECK_FLAG(re->status, ROUTE_ENTRY_QUEUED))
                        json_object_boolean_true_add(json_route, "queued");
 
-               if (re->type != ZEBRA_ROUTE_CONNECT) {
-                       json_object_int_add(json_route, "distance",
-                                           re->distance);
-                       json_object_int_add(json_route, "metric", re->metric);
-               }
-
                if (re->tag)
                        json_object_int_add(json_route, "tag", re->tag);