diff options
author | Eric Dumazet <edumazet@google.com> | 2015-03-13 23:51:10 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-03-14 20:05:10 +0100 |
commit | 16f86165bd0a94a96ab99629828cc9057db50221 (patch) | |
tree | abb1a7c6f69f2f424dd08e035091945d252dd141 /net/dccp/ipv4.c | |
parent | Merge branch 'tipc-next' (diff) | |
download | linux-16f86165bd0a94a96ab99629828cc9057db50221.tar.xz linux-16f86165bd0a94a96ab99629828cc9057db50221.zip |
inet: fill request sock ir_iif for IPv4
Once request socks will be in ehash table, they will need to have
a valid ir_iff field.
This is currently true only for IPv6. This patch extends support
for IPv4 as well.
This means inet_diag_fill_req() can now properly use ir_iif,
which is better for IPv6 link locals anyway, as request sockets
and established sockets will propagate consistent netlink idiag_if.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dccp/ipv4.c')
-rw-r--r-- | net/dccp/ipv4.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/dccp/ipv4.c b/net/dccp/ipv4.c index 8f6f4004daac..7f6456afbaec 100644 --- a/net/dccp/ipv4.c +++ b/net/dccp/ipv4.c @@ -643,6 +643,7 @@ int dccp_v4_conn_request(struct sock *sk, struct sk_buff *skb) ireq->ir_rmt_addr = ip_hdr(skb)->saddr; write_pnet(&ireq->ireq_net, sock_net(sk)); ireq->ireq_family = AF_INET; + ireq->ir_iif = sk->sk_bound_dev_if; /* * Step 3: Process LISTEN state |