rand_unix.c: don't discard entropy bytes from syscall_random()
authorDr. Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com>
Thu, 16 Aug 2018 19:05:47 +0000 (21:05 +0200)
committerDr. Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com>
Sun, 19 Aug 2018 10:44:05 +0000 (12:44 +0200)
commit630ce41e836a756423c7d834fa2b4a0f8efec871
treeb13928ba107439b462acf57b75be530f6bde114c
parent9b5f1c8fd81c01bbaa0aeca0f97e65fee4ab9745
rand_unix.c: don't discard entropy bytes from syscall_random()

Fixes #6978

Don't discard partial reads from syscall_random() and retry instead.

Reviewed-by: Andy Polyakov <appro@openssl.org>
Reviewed-by: Paul Dale <paul.dale@oracle.com>
Reviewed-by: Tim Hudson <tjh@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/6990)
crypto/rand/rand_unix.c