[Lldb-commits] [PATCH] D30288: Switch NetBSD from paccept(2) to accept4(2)

Kamil Rytarowski via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Feb 23 01:26:26 PST 2017


krytarowski created this revision.
krytarowski added a project: LLDB.

NetBSD 8.0 will ship with accept4(2) in libc wrapping paccept(2).

This change reduces needless difference with other platforms.

Older versions of NetBSD will not be supported.

No functional change.

Sponsored by <The NetBSD Foundation>


Repository:
  rL LLVM

https://reviews.llvm.org/D30288

Files:
  source/Host/common/Socket.cpp


Index: source/Host/common/Socket.cpp
===================================================================
--- source/Host/common/Socket.cpp
+++ source/Host/common/Socket.cpp
@@ -443,11 +443,7 @@
   if (!child_processes_inherit) {
     flags |= SOCK_CLOEXEC;
   }
-#if defined(__NetBSD__)
-  NativeSocket fd = ::paccept(sockfd, addr, addrlen, nullptr, flags);
-#else
   NativeSocket fd = ::accept4(sockfd, addr, addrlen, flags);
-#endif
 #else
   NativeSocket fd = ::accept(sockfd, addr, addrlen);
 #endif


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D30288.89476.patch
Type: text/x-patch
Size: 504 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20170223/cbd80804/attachment.bin>


More information about the lldb-commits mailing list