Commit 364e03f
tcp: Reset bytes_acked and bytes_received when disconnecting
[ Upstream commit e858faf ]
If an app is playing tricks to reuse a socket via tcp_disconnect(),
bytes_acked/received needs to be reset to 0. Otherwise tcp_info will
report the sum of the current and the old connection..
Cc: Eric Dumazet <edumazet@google.com>
Fixes: 0df48c2 ("tcp: add tcpi_bytes_acked to tcp_info")
Fixes: bdd1f9e ("tcp: add tcpi_bytes_received to tcp_info")
Signed-off-by: Christoph Paasch <cpaasch@apple.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent 6870759 commit 364e03f
1 file changed
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2272 | 2272 | | |
2273 | 2273 | | |
2274 | 2274 | | |
| 2275 | + | |
| 2276 | + | |
2275 | 2277 | | |
2276 | 2278 | | |
2277 | 2279 | | |
| |||
0 commit comments