]> git.puffer.fish Git - matthieu/frr.git/commitdiff
zebra: only write vni config under vrf if the vni is valid
authorMitesh Kanjariya <mitesh@marvel-07.cumulusnetworks.com>
Sun, 22 Oct 2017 10:46:49 +0000 (03:46 -0700)
committerMitesh Kanjariya <mitesh@marvel-07.cumulusnetworks.com>
Thu, 14 Dec 2017 18:57:07 +0000 (10:57 -0800)
Signed-off-by: Mitesh Kanjariya <mitesh@cumulusnetworks.com>
zebra/zebra_vrf.c

index d2e3f94b476079a3d69da28bd21738f6fd94f508..1ae9eac61fffb6c4dea0632cf419d2af5f8b22d7 100644 (file)
@@ -478,7 +478,8 @@ static int vrf_config_write(struct vty *vty)
 
                if (strcmp(zvrf_name(zvrf), VRF_DEFAULT_NAME)) {
                        vty_out(vty, "vrf %s\n", zvrf_name(zvrf));
-                       vty_out(vty, " vni %u\n", zvrf->l3vni);
+                       if (zvrf->l3vni)
+                               vty_out(vty, " vni %u\n", zvrf->l3vni);
                        vty_out(vty, "!\n");
                }
        }