IPv6: use ipv6_addr_copy() in ip6_route_redirect()
authorBrian Haley <brian.haley@hp.com>
Wed, 7 Oct 2009 20:58:01 +0000 (13:58 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 7 Oct 2009 20:58:01 +0000 (13:58 -0700)
Change ip6_route_redirect() to use ipv6_addr_copy().

Signed-off-by: Brian Haley <brian.haley@hp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/route.c

index d6fe7646a8ff7d8599c3565e6e6c9deb68732cef..df9432a46ffc52f80c21f8e187d52374e8203fe8 100644 (file)
@@ -1471,9 +1471,10 @@ static struct rt6_info *ip6_route_redirect(struct in6_addr *dest,
                                },
                        },
                },
-               .gateway = *gateway,
        };
 
+       ipv6_addr_copy(&rdfl.gateway, gateway);
+
        if (rt6_need_strict(dest))
                flags |= RT6_LOOKUP_F_IFACE;