From e0d101dc3a2b63e5e4386cec52b2632de96f7f5e Mon Sep 17 00:00:00 2001 From: Gerard Wagener Date: Fri, 5 Apr 2019 15:59:02 +0200 Subject: [PATCH] chg: [client] try to compile on openbsd --- client/others/uuid/randutils.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/client/others/uuid/randutils.c b/client/others/uuid/randutils.c index 278f305..48b36fc 100644 --- a/client/others/uuid/randutils.c +++ b/client/others/uuid/randutils.c @@ -100,11 +100,15 @@ int random_get_fd(void) int my_getentropy(void *buf, size_t buflen) { + #ifdef __GLIBC__ if (buflen > 256) { errno = EIO; return -1; } return syscall(SYS_getrandom, buf, buflen, 0); + #else + return getentropy(buf, buflen); + #endif } /*