Skip to content

Commit e0d101d

Browse files
committed
chg: [client] try to compile on openbsd
1 parent 60cfbcb commit e0d101d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

client/others/uuid/randutils.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,11 +100,15 @@ int random_get_fd(void)
100100

101101
int my_getentropy(void *buf, size_t buflen)
102102
{
103+
#ifdef __GLIBC__
103104
if (buflen > 256) {
104105
errno = EIO;
105106
return -1;
106107
}
107108
return syscall(SYS_getrandom, buf, buflen, 0);
109+
#else
110+
return getentropy(buf, buflen);
111+
#endif
108112
}
109113

110114
/*

0 commit comments

Comments
 (0)