cederom commented on PR #2595:
URL: https://github.com/apache/nuttx-apps/pull/2595#issuecomment-2367196057

   Okay quick check reveals:
   * `accept` is part of ` POSIX.1-2008` standard (history: POSIX.1-2001, SVr4, 
4.4BSD, first appeared in 4.2BSD).
   * `accept4` is not standard compliant Linux extension but offers increased 
security (history: Linux 2.6.28, glibc 2.10).
   * Even my FreeBSD has `accept4` defined in `/usr/include/sys/syscall.h`.
   * macOS does not seem to have `accept4` syscall implemented. The only place 
I found was GoLang internal implementation, and some Perl and Python checks if 
system supports it.
   * We have no other way than to use more secure `accept4` on systems that 
supports it and fallback to `accept` on systems that don't :-)


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to