aboutsummaryrefslogtreecommitdiff
path: root/tests/compat_pair.c
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2024-10-06 10:58:54 -0700
committerGarrett D'Amore <garrett@damore.org>2024-10-06 11:18:07 -0700
commit773950e6e1344c435b66fd2a67baebfe4d41a44c (patch)
tree7cc57cd64527f59dcc6e89206e95ba259214606f /tests/compat_pair.c
parent4ae376e827e777acb2acca5e656f6ba59c439200 (diff)
downloadnng-773950e6e1344c435b66fd2a67baebfe4d41a44c.tar.gz
nng-773950e6e1344c435b66fd2a67baebfe4d41a44c.tar.bz2
nng-773950e6e1344c435b66fd2a67baebfe4d41a44c.zip
posix: add getentropy() based RNG
XPG8 defines getentropy() as the only good source for random numbers. However, real world use a bit more nuanced. On BSD systems, we would prefer to use arc4random as it avoids unnecessary system calls. On Linux however, getentropy is implemented in terms of getrandom, and should be used directly when available.
Diffstat (limited to 'tests/compat_pair.c')
0 files changed, 0 insertions, 0 deletions