mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
ipv4: Don't add TCP-code in inet_sock_destruct
Signed-off-by: Christoph Paasch <[email protected]> Acked-by: H.K. Jerry Chu <[email protected]> Acked-by: Eric Dumazet <[email protected]> Signed-off-by: David S. Miller <[email protected]>
This commit is contained in:
parent
9baa0b0364
commit
bb68b64724
3 changed files with 11 additions and 2 deletions
|
|
@ -149,8 +149,6 @@ void inet_sock_destruct(struct sock *sk)
|
|||
pr_err("Attempt to release alive inet socket %p\n", sk);
|
||||
return;
|
||||
}
|
||||
if (sk->sk_protocol == IPPROTO_TCP)
|
||||
kfree(inet_csk(sk)->icsk_accept_queue.fastopenq);
|
||||
|
||||
WARN_ON(atomic_read(&sk->sk_rmem_alloc));
|
||||
WARN_ON(atomic_read(&sk->sk_wmem_alloc));
|
||||
|
|
|
|||
|
|
@ -2325,6 +2325,13 @@ int tcp_disconnect(struct sock *sk, int flags)
|
|||
}
|
||||
EXPORT_SYMBOL(tcp_disconnect);
|
||||
|
||||
void tcp_sock_destruct(struct sock *sk)
|
||||
{
|
||||
inet_sock_destruct(sk);
|
||||
|
||||
kfree(inet_csk(sk)->icsk_accept_queue.fastopenq);
|
||||
}
|
||||
|
||||
static inline bool tcp_can_repair_sock(const struct sock *sk)
|
||||
{
|
||||
return capable(CAP_NET_ADMIN) &&
|
||||
|
|
|
|||
Loading…
Reference in a new issue