Skip to content
This repository was archived by the owner on Sep 2, 2020. It is now read-only.

Commit df6073f

Browse files
committed
Prefer native ppoll over kqueue
ppoll(2) on FreeBSD and OpenBSD isn't broken: - timeout argument remains unmodified unlike on Linux - no ppoll(3) means sigmask is updated atomically unlike with glibc
1 parent a682c99 commit df6073f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

fs.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,9 +100,11 @@ int dup3(int oldfd, int newfd, int flags);
100100

101101
#if defined(__linux__)
102102
# define XPPOLL XPPOLL_LINUX_SYSCALL
103+
#elif defined(HAVE_PPOLL) && !defined(__GLIBC__)
104+
# define XPPOLL XPPOLL_SYSTEM
103105
#elif defined(HAVE_KQUEUE)
104106
# define XPPOLL XPPOLL_KQUEUE
105-
#elif defined(HAVE_PPOLL)
107+
#elif defined(HAVE_PPOLL) && defined(__GLIBC__)
106108
# define XPPOLL XPPOLL_SYSTEM
107109
# define XPPOLL_BROKEN 1
108110
#else

0 commit comments

Comments
 (0)