fjpanag commented on code in PR #7525: URL: https://github.com/apache/nuttx/pull/7525#discussion_r1045620280
########## net/tcp/tcp_conn.c: ########## @@ -549,16 +549,25 @@ FAR struct tcp_conn_s *tcp_alloc_conn(void) if (dq_peek(&g_free_tcp_connections) == NULL) { +#if CONFIG_NET_TCP_MAX_CONNS > 0 + if (dq_count(&g_active_tcp_connections) + CONFIG_NET_TCP_ALLOC_CONNS Review Comment: No, this is correct. The calculation adds the existing connections with those that are about to be allocated. The sum of them must not exceed the limit. I don't see the meaning of `CONFIG_NET_TCP_PREALLOC_CONNS` here. -- 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