mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-25 00:20:53 +07:00
tcp: remove redundant checks II
For same reasons than in commit 12e25e1041
("tcp: remove redundant
checks"), we can remove redundant checks done for timewait sockets.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
908e80d654
commit
98da81a426
@ -1671,10 +1671,6 @@ int tcp_v4_rcv(struct sk_buff *skb)
|
||||
goto discard_it;
|
||||
}
|
||||
|
||||
if (skb->len < (th->doff << 2)) {
|
||||
inet_twsk_put(inet_twsk(sk));
|
||||
goto bad_packet;
|
||||
}
|
||||
if (tcp_checksum_complete(skb)) {
|
||||
inet_twsk_put(inet_twsk(sk));
|
||||
goto csum_error;
|
||||
|
@ -1467,10 +1467,6 @@ static int tcp_v6_rcv(struct sk_buff *skb)
|
||||
|
||||
tcp_v6_fill_cb(skb, hdr, th);
|
||||
|
||||
if (skb->len < (th->doff<<2)) {
|
||||
inet_twsk_put(inet_twsk(sk));
|
||||
goto bad_packet;
|
||||
}
|
||||
if (tcp_checksum_complete(skb)) {
|
||||
inet_twsk_put(inet_twsk(sk));
|
||||
goto csum_error;
|
||||
|
Loading…
Reference in New Issue
Block a user