]> git.puffer.fish Git - mirror/frr.git/commitdiff
zebra: Allow duplicate entry of a route
authorDonald Sharp <sharpd@cumulusnetworks.com>
Fri, 16 Mar 2018 22:38:25 +0000 (18:38 -0400)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Fri, 16 Mar 2018 22:38:25 +0000 (18:38 -0400)
If a user enters a route inside a non kernel existant vrf:

vrf BLOOP
  ip route 4.3.2.0/24 192.168.201.1
!

They should be able to enter it over and over and over and
over and over no matter how futile it is.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
zebra/zebra_vty.c

index ea4d1a9feb213764d3081afdb16eeb9a7784ab68..d0e2529924debc9bbb9464979c333e54f715c26b 100644 (file)
@@ -249,7 +249,11 @@ static int zebra_static_route_holdem(struct zebra_vrf *zvrf,
                        return CMD_SUCCESS;
                }
 
-               assert(!"We should not have found a duplicate and not remove it");
+               /*
+                * If a person enters the same line again
+                * we need to silently accept it
+                */
+               return CMD_SUCCESS;
        }
 
        listnode_add_sort(static_list, shr);