]> git.puffer.fish Git - matthieu/frr.git/commitdiff
zebra: Fix use before initialized
authorDonald Sharp <sharpd@cumulusnetworks.com>
Tue, 15 Jan 2019 12:21:22 +0000 (07:21 -0500)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Sat, 26 Jan 2019 01:14:38 +0000 (20:14 -0500)
When we discover that a command given to the route add/delete
function in rt_socket.c is bogus, print out a debug message
but don't attempt to actually use a nexthop that we have not
figured out yet as part of the data.

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

index 9cc2efb3e9fe1cb01fcb3d3558dc9deb6137cbb1..f25259f300cef721a1edf47fb91a57d07d212a93 100644 (file)
@@ -92,10 +92,9 @@ static int kernel_rtm(int cmd, const struct prefix *p,
         */
        if (cmd != RTM_ADD && cmd != RTM_DELETE) {
                if (IS_ZEBRA_DEBUG_KERNEL)
-                       zlog_debug("%s: %s odd command %s for flags %d",
+                       zlog_debug("%s: %s odd command %s",
                                   __func__, prefix_buf,
-                                  lookup_msg(rtm_type_str, cmd, NULL),
-                                  nexthop->flags);
+                                  lookup_msg(rtm_type_str, cmd, NULL));
                return 0;
        }