net: Fix "Support nuking IPv6 sockets as well as IPv4" for 2.6.39
authorColin Cross <ccross@android.com>
Tue, 3 May 2011 00:23:45 +0000 (17:23 -0700)
committermgross <mark.gross@intel.com>
Wed, 9 Nov 2011 20:07:35 +0000 (12:07 -0800)
Change-Id: I247b8dc2e32bb83e731209928600e92892dd042c
Signed-off-by: Colin Cross <ccross@android.com>
net/ipv4/tcp.c

index a162a0d..d1e438f 100644 (file)
@@ -3326,8 +3326,9 @@ void __init tcp_init(void)
 
 static int tcp_is_local(struct net *net, __be32 addr) {
        struct rtable *rt;
-       struct flowi fl = { .nl_u = { .ip4_u = { .daddr = addr } } };
-       if (ip_route_output_key(net, &rt, &fl) || !rt)
+       struct flowi4 fl4 = { .daddr = addr };
+       rt = ip_route_output_key(net, &fl4);
+       if (!rt)
                return 0;
        return rt->dst.dev && (rt->dst.dev->flags & IFF_LOOPBACK);
 }