DRBG: unify initialization and cleanup code
authorDr. Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com>
Thu, 8 Feb 2018 21:46:23 +0000 (22:46 +0100)
committerDr. Matthias St. Pierre <Matthias.St.Pierre@ncp-e.com>
Tue, 13 Feb 2018 16:32:54 +0000 (17:32 +0100)
commit4f9dabbfe30c3539dd6cb0bd861ddb0127c11c20
treec2db0affead1c145e520dd819a7aecf2aa897c10
parent3ce1c27b56fa9856693e5c98331cebaa2a3accfa
DRBG: unify initialization and cleanup code

The functions drbg_setup() and drbg_cleanup() used to duplicate a lot of
code from RAND_DRBG_new() and RAND_DRBG_free(). This duplication has been
removed, which simplifies drbg_setup() and makes drbg_cleanup() obsolete.

Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/5294)
crypto/rand/drbg_lib.c
crypto/rand/rand_lcl.h
include/internal/rand.h
util/libcrypto.num