diff options
author | NIIBE Yutaka <gniibe@fsij.org> | 2022-01-26 00:50:43 +0900 |
---|---|---|
committer | NIIBE Yutaka <gniibe@fsij.org> | 2022-01-26 00:50:43 +0900 |
commit | 5e2d792eb8d9e5aaf1b71205f9298286b8145462 (patch) | |
tree | 1fa8a4002a741faa8f4ddb9ca10e568774563569 /random | |
parent | bafdb90d97b65db541ea917088ca956e6a364f6b (diff) | |
download | libgcrypt-5e2d792eb8d9e5aaf1b71205f9298286b8145462.tar.gz |
random: Include sys/random.h when available.
* configure.ac (AC_CHECK_HEADERS): Check sys/random.h.
* random/rndgetentropy.c [HAVE_SYS_RANDOM_H]: Include it.
--
Reported-by: Christoph Badura <bad@bsd.de>
Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
Diffstat (limited to 'random')
-rw-r--r-- | random/rndgetentropy.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/random/rndgetentropy.c b/random/rndgetentropy.c index a64b7299..7580873e 100644 --- a/random/rndgetentropy.c +++ b/random/rndgetentropy.c @@ -26,6 +26,9 @@ #include <sys/types.h> #include <string.h> #include <unistd.h> +#ifdef HAVE_SYS_RANDOM_H +#include <sys/random.h> +#endif #include "types.h" #include "g10lib.h" |