summaryrefslogtreecommitdiffstats
path: root/lib/libcrypto/crypto/getentropy_linux.c
diff options
context:
space:
mode:
authorbcook <bcook@openbsd.org>2015-04-27 03:37:06 +0000
committerbcook <bcook@openbsd.org>2015-04-27 03:37:06 +0000
commit3e3a5746bf2e82123111ef7a676cdb9ce1e1ea13 (patch)
tree3d40eeeddbb746e5f402f6f9409223547b39e22d /lib/libcrypto/crypto/getentropy_linux.c
parentSupport AIX versions without WPAR support. (diff)
downloadwireguard-openbsd-3e3a5746bf2e82123111ef7a676cdb9ce1e1ea13.tar.xz
wireguard-openbsd-3e3a5746bf2e82123111ef7a676cdb9ce1e1ea13.zip
Not all Linux libc's include linux/sysctl.h in sys/sysctl.h.
Include it if we have the sysctl syscall.
Diffstat (limited to 'lib/libcrypto/crypto/getentropy_linux.c')
-rw-r--r--lib/libcrypto/crypto/getentropy_linux.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/libcrypto/crypto/getentropy_linux.c b/lib/libcrypto/crypto/getentropy_linux.c
index 29e7efe234a..4fce68c25b3 100644
--- a/lib/libcrypto/crypto/getentropy_linux.c
+++ b/lib/libcrypto/crypto/getentropy_linux.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: getentropy_linux.c,v 1.37 2015/03/22 13:28:03 bcook Exp $ */
+/* $OpenBSD: getentropy_linux.c,v 1.38 2015/04/27 03:37:06 bcook Exp $ */
/*
* Copyright (c) 2014 Theo de Raadt <deraadt@openbsd.org>
@@ -27,8 +27,9 @@
#include <sys/ioctl.h>
#include <sys/resource.h>
#include <sys/syscall.h>
-#ifdef HAVE_SYS_SYSCTL_H
+#ifdef SYS__sysctl
#include <sys/sysctl.h>
+#include <linux/sysctl.h>
#endif
#include <sys/statvfs.h>
#include <sys/socket.h>