]> git.ipfire.org Git - thirdparty/coreutils.git/commit
maint: use getrandom, not getentropy
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 1 Jun 2020 22:53:27 +0000 (15:53 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 1 Jun 2020 22:54:50 +0000 (15:54 -0700)
commitb4ab357e42f53411ccc1aac38ee637de140abc0f
tree160af93771f10616b0b222ecb5c038c2b77af41e
parentb3ff4113fddd169bff8b237764d9bea428ecb804
maint: use getrandom, not getentropy

This makes for one Gnulib module less, and at runtime there’s
typically just one getrandom syscall instead of several for large
nonces.
* gl/lib/randread.c: Include sys/random.h instead of sys/time.h
and unistd.h.
(get_nonce): Use getrandom, not getentropy.
* gl/modules/randread (Depends-on):
Depend on getrandom, not getentropy.
* src/shred.c (main):
* src/shuf.c (main):
* src/sort.c (random_md5_state_init):
Say "getrandom" rather than "getentropy" in (unlikely) diagnostic.
gl/lib/randread.c
gl/modules/randread
src/shred.c
src/shuf.c
src/sort.c