[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20140321142400.6775cd80@nehalam.linuxnetplumber.net>
Date: Fri, 21 Mar 2014 14:24:00 -0700
From: Stephen Hemminger <stephen@...workplumber.org>
To: Mike Rapoport <mike.rapoport@...ellosystems.com>
Cc: netdev@...r.kernel.org
Subject: Re: [PATCH iproute2] bridge: fix reporting of IPv6 addresses
On Thu, 20 Mar 2014 13:06:10 +0200
Mike Rapoport <mike.rapoport@...ellosystems.com> wrote:
> Signed-off-by: Mike Rapoport <mike.rapoport@...ellosystems.com>
> ---
> bridge/fdb.c | 7 ++++++-
> 1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/bridge/fdb.c b/bridge/fdb.c
> index e2e53f1..9b720e3 100644
> --- a/bridge/fdb.c
> +++ b/bridge/fdb.c
> @@ -103,8 +103,13 @@ int print_fdb(const struct sockaddr_nl *who, struct nlmsghdr *n, void *arg)
>
> if (tb[NDA_DST]) {
> SPRINT_BUF(abuf);
> + int family = AF_INET;
> +
> + if (RTA_PAYLOAD(tb[NDA_DST]) == sizeof(struct in6_addr))
> + family = AF_INET6;
> +
> fprintf(fp, "dst %s ",
> - format_host(AF_INET,
> + format_host(family,
> RTA_PAYLOAD(tb[NDA_DST]),
> RTA_DATA(tb[NDA_DST]),
> abuf, sizeof(abuf)));
Looks good applied.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists