summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorRomain Kuntz <r.kuntz@ipflavors.com>2013-01-09 18:02:26 +0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-02-14 22:48:54 +0400
commit3b69055b43c57783a8bf99a8e40f773580e451a1 (patch)
treeacf7a6f31138e0642b1233c56dcd43c9112d777c /net
parent0ad715758022062a34bccede6200803e26480c97 (diff)
downloadlinux-3b69055b43c57783a8bf99a8e40f773580e451a1.tar.xz
ipv6: fix the noflags test in addrconf_get_prefix_route
[ Upstream commit 85da53bf1c336bb07ac038fb951403ab0478d2c5 ] The tests on the flags in addrconf_get_prefix_route() does no make much sense: the 'noflags' parameter contains the set of flags that must not match with the route flags, so the test must be done against 'noflags', and not against 'flags'. Signed-off-by: Romain Kuntz <r.kuntz@ipflavors.com> Acked-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net')
-rw-r--r--net/ipv6/addrconf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv6/addrconf.c b/net/ipv6/addrconf.c
index 468a5ce6e9d2..81e0ad2442c7 100644
--- a/net/ipv6/addrconf.c
+++ b/net/ipv6/addrconf.c
@@ -1736,7 +1736,7 @@ static struct rt6_info *addrconf_get_prefix_route(const struct in6_addr *pfx,
continue;
if ((rt->rt6i_flags & flags) != flags)
continue;
- if ((noflags != 0) && ((rt->rt6i_flags & flags) != 0))
+ if ((rt->rt6i_flags & noflags) != 0)
continue;
dst_hold(&rt->dst);
break;