Re: [PATCH net] ipv4: don't set IPv6 only flags to IPv4 addresses

From: Matteo Croce
Date: Mon Jul 01 2019 - 12:14:12 EST


On Mon, Jul 1, 2019 at 6:10 PM Joe Perches <joe@xxxxxxxxxxx> wrote:
>
> On Mon, 2019-07-01 at 18:08 +0200, Matteo Croce wrote:
> > Avoid the situation where an IPV6 only flag is applied to an IPv4 address:
> []
> > diff --git a/net/ipv4/devinet.c b/net/ipv4/devinet.c
> []
> > @@ -468,6 +473,9 @@ static int __inet_insert_ifa(struct in_ifaddr *ifa, struct nlmsghdr *nlh,
> > ifa->ifa_flags &= ~IFA_F_SECONDARY;
> > last_primary = &in_dev->ifa_list;
> >
> > + /* Don't set IPv6 only flags to IPv6 addresses */
>
> umm, IPv4 addresses?
>
>

Ouch, right.

/* Don't set IPv6 only flags to IPv4 addresses */

Can this be edidet on patchwork instead of spamming with a v2?

--
Matteo Croce
per aspera ad upstream