Change-Id: Ia9048bb4e074f7ebc36eb77e542a916924103332
Signed-off-by: Florin Coras <fcoras@cisco.com>
{
tc = tcp_half_open_connection_get (index);
/* Note: the connection may have transitioned to ESTABLISHED... */
{
tc = tcp_half_open_connection_get (index);
/* Note: the connection may have transitioned to ESTABLISHED... */
- if (PREDICT_FALSE (tc == 0))
+ if (PREDICT_FALSE (tc == 0 || tc->state != TCP_STATE_SYN_SENT))
return;
tc->timers[TCP_TIMER_RETRANSMIT_SYN] = TCP_TIMER_HANDLE_INVALID;
}
return;
tc->timers[TCP_TIMER_RETRANSMIT_SYN] = TCP_TIMER_HANDLE_INVALID;
}
{
tc = tcp_connection_get (index, thread_index);
/* Note: the connection may have been closed and pool_put */
{
tc = tcp_connection_get (index, thread_index);
/* Note: the connection may have been closed and pool_put */
- if (PREDICT_FALSE (tc == 0))
+ if (PREDICT_FALSE (tc == 0 || tc->state < TCP_STATE_SYN_RCVD))
return;
tc->timers[TCP_TIMER_RETRANSMIT] = TCP_TIMER_HANDLE_INVALID;
}
return;
tc->timers[TCP_TIMER_RETRANSMIT] = TCP_TIMER_HANDLE_INVALID;
}