Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 19050
b: refs/heads/master
c: 81845c2
h: refs/heads/master
v: v3
  • Loading branch information
Vlad Yasevich authored and David S. Miller committed Jan 30, 2006
1 parent 72e6e68 commit 9ca6a63
Show file tree
Hide file tree
Showing 3 changed files with 5 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: 7add2a439868d636910fb6a216b12c7392778956
refs/heads/master: 81845c21dc1ec7ce2bf12845dbc01e4880f9ea9a
6 changes: 3 additions & 3 deletions trunk/net/sctp/sm_statefuns.c
Original file line number Diff line number Diff line change
Expand Up @@ -2122,7 +2122,7 @@ static sctp_disposition_t sctp_sf_do_5_2_6_stale(const struct sctp_endpoint *ep,
struct sctp_bind_addr *bp;
int attempts = asoc->init_err_counter + 1;

if (attempts >= asoc->max_init_attempts) {
if (attempts > asoc->max_init_attempts) {
sctp_add_cmd_sf(commands, SCTP_CMD_INIT_FAILED,
SCTP_U32(SCTP_ERROR_STALE_COOKIE));
return SCTP_DISPOSITION_DELETE_TCB;
Expand Down Expand Up @@ -4640,7 +4640,7 @@ sctp_disposition_t sctp_sf_t1_init_timer_expire(const struct sctp_endpoint *ep,

SCTP_DEBUG_PRINTK("Timer T1 expired (INIT).\n");

if (attempts < asoc->max_init_attempts) {
if (attempts <= asoc->max_init_attempts) {
bp = (struct sctp_bind_addr *) &asoc->base.bind_addr;
repl = sctp_make_init(asoc, bp, GFP_ATOMIC, 0);
if (!repl)
Expand Down Expand Up @@ -4697,7 +4697,7 @@ sctp_disposition_t sctp_sf_t1_cookie_timer_expire(const struct sctp_endpoint *ep

SCTP_DEBUG_PRINTK("Timer T1 expired (COOKIE-ECHO).\n");

if (attempts < asoc->max_init_attempts) {
if (attempts <= asoc->max_init_attempts) {
repl = sctp_make_cookie_echo(asoc, NULL);
if (!repl)
return SCTP_DISPOSITION_NOMEM;
Expand Down
2 changes: 1 addition & 1 deletion trunk/net/sctp/socket.c
Original file line number Diff line number Diff line change
Expand Up @@ -5426,7 +5426,7 @@ static int sctp_wait_for_connect(struct sctp_association *asoc, long *timeo_p)
return err;

do_error:
if (asoc->init_err_counter + 1 >= asoc->max_init_attempts)
if (asoc->init_err_counter + 1 > asoc->max_init_attempts)
err = -ETIMEDOUT;
else
err = -ECONNREFUSED;
Expand Down

0 comments on commit 9ca6a63

Please sign in to comment.