You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by pk...@apache.org on 2022/08/17 18:35:15 UTC

[incubator-nuttx] branch master updated: tcp: reset conn->nrtx when ack received

This is an automated email from the ASF dual-hosted git repository.

pkarashchenko pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git


The following commit(s) were added to refs/heads/master by this push:
     new e03c2c321a tcp: reset conn->nrtx when ack received
e03c2c321a is described below

commit e03c2c321a84035503a9daba02f887cc8d34f842
Author: zhanghongyu <zh...@xiaomi.com>
AuthorDate: Tue Jul 26 14:03:48 2022 +0800

    tcp: reset conn->nrtx when ack received
    
    Otherwise, when a long test triggers multiple timeout retransmissions,
    the late timeout retransmissions are always delayed between 24 and 48 seconds
    
    Signed-off-by: zhanghongyu <zh...@xiaomi.com>
---
 net/tcp/tcp_input.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/net/tcp/tcp_input.c b/net/tcp/tcp_input.c
index f51c17a4cf..0c65a515f4 100644
--- a/net/tcp/tcp_input.c
+++ b/net/tcp/tcp_input.c
@@ -773,6 +773,7 @@ found:
                     tcp_getsequence(conn->sndseq), ackseq, unackseq,
                     (uint32_t)conn->tx_unacked);
               tcp_setsequence(conn->sndseq, ackseq);
+              conn->nrtx = 0;
             }
         }
 #endif