Skip to content
Commit c3658e8d authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller
Browse files

tcp: fix possible NULL dereference in tcp_vX_send_reset()

After commit ca777eff ("tcp: remove dst refcount false sharing for
prequeue mode") we have to relax check against skb dst in
tcp_v[46]_send_reset() if prequeue dropped the dst.

If a socket is provided, a full lookup was done to find this socket,
so the dst test can be skipped.

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=88191


Reported-by: default avatarJaša Bartelj <jasa.bartelj@gmail.com>
Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
Reported-by: default avatarDaniel Borkmann <dborkman@redhat.com>
Fixes: ca777eff ("tcp: remove dst refcount false sharing for prequeue mode")
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 43612d7c
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment