From: Tomas Paukrt Date: Tue, 8 Oct 2019 09:51:48 +0000 (+0200) Subject: route: fix output of "route -n -A inet6" X-Git-Tag: 1_32_0~147 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=4527273f1c5bca044577f2f8ed2d7e4f203bf485;p=oweals%2Fbusybox.git route: fix output of "route -n -A inet6" The output of the command "route -n -A inet6" may be corrupted due to partially initialized structure snaddr6 in the function INET6_displayroutes. Signed-off-by: Tomas Paukrt Signed-off-by: Denys Vlasenko --- diff --git a/networking/route.c b/networking/route.c index a5d8d7cb9..e785b1da6 100644 --- a/networking/route.c +++ b/networking/route.c @@ -628,6 +628,7 @@ static void INET6_displayroutes(void) r = 0; while (1) { + memset(&snaddr6, 0, sizeof(snaddr6)); inet_pton(AF_INET6, addr6x + r, (struct sockaddr *) &snaddr6.sin6_addr); snaddr6.sin6_family = AF_INET6;