anchao commented on a change in pull request #5526: URL: https://github.com/apache/incubator-nuttx/pull/5526#discussion_r809069471
########## File path: net/tcp/tcp_send_buffered.c ########## @@ -1172,7 +1204,12 @@ ssize_t psock_tcp_send(FAR struct socket *psock, FAR const void *buf, goto errout_with_lock; } - net_lockedwait_uninterruptible(&conn->snd_sem); + remain = tcp_send_gettimeout(anchor, remain); + ret = net_timedwait_uninterruptible(&conn->snd_sem, remain); Review comment: I can keep the anchor prototype as clock_t, but the remain still needs. remain timeout parameter needs to be calculated dynamically, this time needs to be accumulated ``` 1207 remain = tcp_send_gettimeout(anchor, remain); 1208 ret = net_timedwait_uninterruptible(&conn->snd_sem, remain); //remain changed 1253 remain = tcp_send_gettimeout(anchor, remain); 1254 wrb = tcp_wrbuffer_timedalloc(remain); 1255 ninfo("new wrb %p\n", wrb); 1256 DEBUGASSERT(TCP_WBPKTLEN(wrb) == 0); ... ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org