Skip to content

Commit

Permalink
tcp: Use cork flow info instead of rt->rt_dst in tcp_v4_get_peer()
Browse files Browse the repository at this point in the history
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
David S. Miller committed May 8, 2011
1 parent f1c0a27 commit c5216cc
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion net/ipv4/tcp_ipv4.c
Original file line number Diff line number Diff line change
Expand Up @@ -1773,7 +1773,8 @@ struct inet_peer *tcp_v4_get_peer(struct sock *sk, bool *release_it)
struct inet_sock *inet = inet_sk(sk);
struct inet_peer *peer;

if (!rt || rt->rt_dst != inet->inet_daddr) {
if (!rt ||
inet->cork.fl.u.ip4.daddr != inet->inet_daddr) {
peer = inet_getpeer_v4(inet->inet_daddr, 1);
*release_it = true;
} else {
Expand Down

0 comments on commit c5216cc

Please sign in to comment.