mirror of
https://github.com/torvalds/linux.git
synced 2026-10-07 22:37:45 -04:00
tracepoint tcp_send_reset requires a full socket to work. However, it
may be called when in TCP_TIME_WAIT:
case TCP_TW_RST:
tcp_v6_send_reset(sk, skb);
inet_twsk_deschedule_put(inet_twsk(sk));
goto discard_it;
To avoid this problem, this patch checks the socket with sk_fullsock()
before calling trace_tcp_send_reset().
Fixes: c24b14c46b ("tcp: add tracepoint trace_tcp_send_reset")
Signed-off-by: Song Liu <[email protected]>
Reviewed-by: Lawrence Brakmo <[email protected]>
Signed-off-by: David S. Miller <[email protected]>