You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2021/12/18 13:50:14 UTC

[GitHub] [incubator-nuttx] xiaoxiang781216 commented on a change in pull request #5030: sim/usrsock: reuse the socket address to avoid bind timeout

xiaoxiang781216 commented on a change in pull request #5030:
URL: https://github.com/apache/incubator-nuttx/pull/5030#discussion_r771827508



##########
File path: arch/sim/src/sim/up_usrsock_host.c
##########
@@ -238,6 +239,7 @@ int usrsock_host_socket(int domain, int type, int protocol)
       return -errno;
     }
 
+  setsockopt(ret, SOL_SOCKET, SO_REUSEADDR, &opt, sizeof(opt));

Review comment:
       why the user doesn't call setsockopt with SO_REUSEADDR by self and then let usrsock forward the request to host side?




-- 
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-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org