diff options
author | Eric Dumazet <edumazet@google.com> | 2019-01-17 11:23:42 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-01-17 22:19:05 -0800 |
commit | 6bcdc40dddfe79408e809ec1e2c13f08c863c0b2 (patch) | |
tree | e432d56cc0b4e01edc9e755e231143a6afea0613 /net/ipv4/tcp.c | |
parent | 792c4354a508c42c69f4771287cb99dde4ab79be (diff) | |
download | linux-6bcdc40dddfe79408e809ec1e2c13f08c863c0b2.tar.gz linux-6bcdc40dddfe79408e809ec1e2c13f08c863c0b2.tar.bz2 linux-6bcdc40dddfe79408e809ec1e2c13f08c863c0b2.zip |
tcp: move rx_opt & syn_data_acked init to tcp_disconnect()
If we make sure all listeners have these fields cleared, then a clone
will also inherit zero values.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/tcp.c')
-rw-r--r-- | net/ipv4/tcp.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c index 2348199e6cee..541bdb9f81d7 100644 --- a/net/ipv4/tcp.c +++ b/net/ipv4/tcp.c @@ -2617,6 +2617,10 @@ int tcp_disconnect(struct sock *sk, int flags) tp->rack.last_delivered = 0; tp->rack.reo_wnd_persist = 0; tp->rack.dsack_seen = 0; + tp->syn_data_acked = 0; + tp->rx_opt.saw_tstamp = 0; + tp->rx_opt.dsack = 0; + tp->rx_opt.num_sacks = 0; /* Clean up fastopen related fields */ |