]> git.baikalelectronics.ru Git - kernel.git/commit
ipv6/route: Don't match on fc_nh_id if not set in ip6_route_del()
authorStefano Brivio <sbrivio@redhat.com>
Fri, 21 Jun 2019 15:45:25 +0000 (17:45 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 24 Jun 2019 17:18:49 +0000 (10:18 -0700)
commit5621f0c9b17981f25124a152e00659bed5379463
tree8bc561fc73f4cd6e3d29c5dd617390cdaf7944a9
parentcb5ff649ea0fca6a812d1be5ba9c0575d53e789f
ipv6/route: Don't match on fc_nh_id if not set in ip6_route_del()

If fc_nh_id isn't set, we shouldn't try to match against it. This
actually matters just for the RTF_CACHE below (where this case is
already handled): if iproute2 gets a route exception and tries to
delete it, it won't reference it by fc_nh_id, even if a nexthop
object might be associated to the originating route.

Fixes: d6920b00465b ("ipv6: Allow routes to use nexthop objects")
Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Reviewed-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/route.c