gustavonihei commented on a change in pull request #4179: URL: https://github.com/apache/incubator-nuttx/pull/4179#discussion_r672279701
########## File path: net/rpmsg/rpmsg_sockif.c ########## @@ -505,8 +502,25 @@ static void rpmsg_socket_ns_bind(FAR struct rpmsg_device *rdev, strcpy(new->rpaddr.rp_cpu, rpmsg_get_cpuname(rdev)); strcpy(new->rpaddr.rp_name, name); + rpmsg_socket_lock(&server->recvlock); + + for (tmp = server; tmp->next; tmp = tmp->next) + { + if (++cnt >= server->backlog) + { + /* Reject the connection */ + + rpmsg_destroy_ept(&new->ept); + rpmsg_socket_free(new); + rpmsg_socket_lock(&server->recvlock); Review comment: ```suggestion rpmsg_socket_unlock(&server->recvlock); ``` Shouldn't you unlock here instead? -- 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