tcp: force mss equality with the next skb too.
authorIlpo Järvinen <ilpo.jarvinen@helsinki.fi>
Sat, 6 Dec 2008 06:40:47 +0000 (22:40 -0800)
committerDavid S. Miller <davem@davemloft.net>
Sat, 6 Dec 2008 06:40:47 +0000 (22:40 -0800)
Also make if-goto forest nicer looking.

Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/tcp_input.c

index d67b6e9cc5407ed10d59d77530760db8c304b0b1..63c3ef6d4a1c21b448739176cf31acf872efca61 100644 (file)
@@ -1575,11 +1575,10 @@ static struct sk_buff *tcp_shift_skb_data(struct sock *sk, struct sk_buff *skb,
                goto out;
        skb = tcp_write_queue_next(sk, prev);
 
-       if (!skb_can_shift(skb))
-               goto out;
-       if (skb == tcp_send_head(sk))
-               goto out;
-       if ((TCP_SKB_CB(skb)->sacked & TCPCB_TAGBITS) != TCPCB_SACKED_ACKED)
+       if (!skb_can_shift(skb) ||
+           (skb == tcp_send_head(sk)) ||
+           ((TCP_SKB_CB(skb)->sacked & TCPCB_TAGBITS) != TCPCB_SACKED_ACKED) ||
+           (mss != tcp_shift_mss(skb)))
                goto out;
 
        len = skb->len;