Home GnuPG

random: Call getrandom before select and emitting a progress callback.
e4c0159974b0Unpublished

Unpublished Commit · Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

random: Call getrandom before select and emitting a progress callback.

* random/rndlinux.c (_gcry_rndlinux_gather_random): Move the getrandom
call before the select.

A select for getrandom does not make any sense because there is no
file descriptor for getrandom. Thus if getrandom is available we now
select only when we want to read from the blocking /dev/random. In
most cases this avoids all progress callbacks.

  • Signed-off-by: Werner Koch <wk@gnupg.org>

Details

Provenance
wernerAuthored on Jan 18 2017, 10:18 AM
Parents
rC4dc4748bb6de: Post release updates.
Branches
Unknown
Tags
Unknown

Event Timeline