]> git.puffer.fish Git - mirror/frr.git/commitdiff
zebra: Fix CLANG suggestion for braces on init of struct 3791/head
authorStephen Worley <sworley@cumulusnetworks.com>
Tue, 12 Feb 2019 20:24:00 +0000 (15:24 -0500)
committerStephen Worley <sworley@cumulusnetworks.com>
Tue, 12 Feb 2019 20:24:00 +0000 (15:24 -0500)
CLANG was throwing an error because struct rtadv_rdnss(dnssl) was being
initialized with = {0} instead of {}. Change to be the latter.

Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
zebra/rtadv.c

index fadf8317cc5332faebe3d9263a876b31938144c8..5088e2e8e1f62ad95c04be4477bbf44a7efc0f58 100644 (file)
@@ -1780,7 +1780,7 @@ DEFUN(ipv6_nd_rdnss,
 {
        VTY_DECLVAR_CONTEXT(interface, ifp);
        struct zebra_if *zif = ifp->info;
-       struct rtadv_rdnss rdnss = {0};
+       struct rtadv_rdnss rdnss = {};
 
        if (inet_pton(AF_INET6, argv[3]->arg, &rdnss.addr) != 1) {
                vty_out(vty, "Malformed IPv6 address\n");
@@ -1813,7 +1813,7 @@ DEFUN(no_ipv6_nd_rdnss,
 {
        VTY_DECLVAR_CONTEXT(interface, ifp);
        struct zebra_if *zif = ifp->info;
-       struct rtadv_rdnss rdnss = {0};
+       struct rtadv_rdnss rdnss = {};
 
        if (inet_pton(AF_INET6, argv[4]->arg, &rdnss.addr) != 1) {
                vty_out(vty, "Malformed IPv6 address\n");
@@ -1839,7 +1839,7 @@ DEFUN(ipv6_nd_dnssl,
 {
        VTY_DECLVAR_CONTEXT(interface, ifp);
        struct zebra_if *zif = ifp->info;
-       struct rtadv_dnssl dnssl = {0};
+       struct rtadv_dnssl dnssl = {};
        size_t len;
        int ret;
 
@@ -1889,7 +1889,7 @@ DEFUN(no_ipv6_nd_dnssl,
 {
        VTY_DECLVAR_CONTEXT(interface, ifp);
        struct zebra_if *zif = ifp->info;
-       struct rtadv_dnssl dnssl = {0};
+       struct rtadv_dnssl dnssl = {};
        size_t len;
 
        len = strlcpy(dnssl.name, argv[4]->arg, sizeof(dnssl.name));