fjpanag commented on code in PR #7525: URL: https://github.com/apache/nuttx/pull/7525#discussion_r1111040090
########## net/udp/udp_conn.c: ########## @@ -472,16 +472,25 @@ FAR struct udp_conn_s *udp_alloc_conn(void) if (dq_peek(&g_free_udp_connections) == NULL) { +#if CONFIG_NET_UDP_MAX_CONNS > 0 + if (dq_count(&g_active_udp_connections) + CONFIG_NET_UDP_ALLOC_CONNS + >= CONFIG_NET_UDP_MAX_CONNS) + { + return NULL; + } +#endif + conn = kmm_zalloc(sizeof(struct udp_conn_s) * - CONFIG_NET_UDP_CONNS); + CONFIG_NET_UDP_ALLOC_CONNS); + Review Comment: Done. -- 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