Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 348025
b: refs/heads/master
c: c3ae62a
h: refs/heads/master
i:
  348023: 35d9d35
v: v3
  • Loading branch information
Eric Dumazet authored and David S. Miller committed Dec 26, 2012
1 parent 874c79a commit de54af8
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 3d0dcfbd8fa2a1e63fabb5f8edac8b8a27860d98
refs/heads/master: c3ae62af8e755ea68380fb5ce682e60079a4c388
14 changes: 10 additions & 4 deletions trunk/net/ipv4/tcp_input.c
Original file line number Diff line number Diff line change
Expand Up @@ -5543,6 +5543,9 @@ int tcp_rcv_established(struct sock *sk, struct sk_buff *skb,
if (len < (th->doff << 2) || tcp_checksum_complete_user(sk, skb))
goto csum_error;

if (!th->ack)
goto discard;

/*
* Standard slow path.
*/
Expand All @@ -5551,7 +5554,7 @@ int tcp_rcv_established(struct sock *sk, struct sk_buff *skb,
return 0;

step5:
if (th->ack && tcp_ack(sk, skb, FLAG_SLOWPATH) < 0)
if (tcp_ack(sk, skb, FLAG_SLOWPATH) < 0)
goto discard;

/* ts_recent update must be made after we are sure that the packet
Expand Down Expand Up @@ -5984,11 +5987,15 @@ int tcp_rcv_state_process(struct sock *sk, struct sk_buff *skb,
if (tcp_check_req(sk, skb, req, NULL, true) == NULL)
goto discard;
}

if (!th->ack)
goto discard;

if (!tcp_validate_incoming(sk, skb, th, 0))
return 0;

/* step 5: check the ACK field */
if (th->ack) {
if (true) {
int acceptable = tcp_ack(sk, skb, FLAG_SLOWPATH) > 0;

switch (sk->sk_state) {
Expand Down Expand Up @@ -6138,8 +6145,7 @@ int tcp_rcv_state_process(struct sock *sk, struct sk_buff *skb,
}
break;
}
} else
goto discard;
}

/* ts_recent update must be made after we are sure that the packet
* is in window.
Expand Down

0 comments on commit de54af8

Please sign in to comment.