]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit
tcp: clear icsk_backoff in tcp_write_queue_purge()
authorEric Dumazet <edumazet@google.com>
Fri, 15 Feb 2019 21:36:20 +0000 (13:36 -0800)
committerDavid S. Miller <davem@davemloft.net>
Sun, 17 Feb 2019 23:46:58 +0000 (15:46 -0800)
commit04c03114be82194d4a4858d41dba8e286ad1787c
treefb25d7781f7faf8576f77965e3e586129da4b6aa
parente928b5d6b75e239feb9c6d5488974b6646a0ebc8
tcp: clear icsk_backoff in tcp_write_queue_purge()

soukjin bae reported a crash in tcp_v4_err() handling
ICMP_DEST_UNREACH after tcp_write_queue_head(sk)
returned a NULL pointer.

Current logic should have prevented this :

  if (seq != tp->snd_una  || !icsk->icsk_retransmits ||
      !icsk->icsk_backoff || fastopen)
      break;

Problem is the write queue might have been purged
and icsk_backoff has not been cleared.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: soukjin bae <soukjin.bae@samsung.com>
Acked-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/tcp.c