From: Vlad Yasevich Date: Tue, 31 Jan 2006 00:00:40 +0000 (-0800) Subject: [SCTP]: heartbeats exceed maximum retransmssion limit X-Git-Tag: v2.6.16-rc2~252^2~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e2c2fc2c8f3750e1f7ffbb3ac2b885a49416110c;p=profile%2Fivi%2Fkernel-adaptation-intel-automotive.git [SCTP]: heartbeats exceed maximum retransmssion limit The number of HEARTBEAT chunks that an association may transmit is limited by Association.Max.Retrans count; however, the code allows us to send one extra heartbeat. This patch limits the number of heartbeats to the maximum count. Signed-off-by: Vlad Yasevich Signed-off-by: Sridhar Samudrala Signed-off-by: David S. Miller --- diff --git a/net/sctp/sm_statefuns.c b/net/sctp/sm_statefuns.c index 018f169..2b9a832 100644 --- a/net/sctp/sm_statefuns.c +++ b/net/sctp/sm_statefuns.c @@ -884,7 +884,7 @@ sctp_disposition_t sctp_sf_sendbeat_8_3(const struct sctp_endpoint *ep, { struct sctp_transport *transport = (struct sctp_transport *) arg; - if (asoc->overall_error_count > asoc->max_retrans) { + if (asoc->overall_error_count >= asoc->max_retrans) { /* CMD_ASSOC_FAILED calls CMD_DELETE_TCB. */ sctp_add_cmd_sf(commands, SCTP_CMD_ASSOC_FAILED, SCTP_U32(SCTP_ERROR_NO_ERROR));