From: David Ahern Date: Thu, 27 Sep 2018 00:35:14 +0000 (-0700) Subject: net/ipv6: Remove extra call to ip6_convert_metrics for multipath case X-Git-Tag: v4.19~103^2~54 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=36f19d5b4f99fa9fa8263877e5f8e669d7fddc14;p=platform%2Fkernel%2Flinux-rpi3.git net/ipv6: Remove extra call to ip6_convert_metrics for multipath case The change to move metrics from the dst to rt6_info moved the call to ip6_convert_metrics from ip6_route_add to ip6_route_info_create. In doing so it makes the call in ip6_route_info_append redundant and actually leaks the metrics installed as part of the ip6_route_info_create. Remove the now unnecessary call. Fixes: d4ead6b34b67f ("net/ipv6: move metrics from dst to rt6_info") Signed-off-by: David Ahern Signed-off-by: David S. Miller --- diff --git a/net/ipv6/route.c b/net/ipv6/route.c index 826b14d..a366c05 100644 --- a/net/ipv6/route.c +++ b/net/ipv6/route.c @@ -4321,11 +4321,6 @@ static int ip6_route_info_append(struct net *net, if (!nh) return -ENOMEM; nh->fib6_info = rt; - err = ip6_convert_metrics(net, rt, r_cfg); - if (err) { - kfree(nh); - return err; - } memcpy(&nh->r_cfg, r_cfg, sizeof(*r_cfg)); list_add_tail(&nh->next, rt6_nh_list);