Define RAND_cleanup in one place only Change-Id: I439e275394c2ad686924f4e7dfc99cfdc7bb14b9 Reviewed-on: https://boringssl-review.googlesource.com/8682 Reviewed-by: Adam Langley <agl@google.com>
diff --git a/crypto/rand/deterministic.c b/crypto/rand/deterministic.c index e6b7bb7..628fd22 100644 --- a/crypto/rand/deterministic.c +++ b/crypto/rand/deterministic.c
@@ -30,8 +30,6 @@ * mutex would not be deterministic.) */ static uint64_t g_num_calls = 0; -void RAND_cleanup(void) {} - void RAND_reset_for_fuzzing(void) { g_num_calls = 0; } void CRYPTO_sysrand(uint8_t *out, size_t requested) {
diff --git a/crypto/rand/rand.c b/crypto/rand/rand.c index 5a1bec2..b73bc3c 100644 --- a/crypto/rand/rand.c +++ b/crypto/rand/rand.c
@@ -240,3 +240,5 @@ } void RAND_set_rand_method(const RAND_METHOD *method) {} + +void RAND_cleanup(void) {}
diff --git a/crypto/rand/urandom.c b/crypto/rand/urandom.c index 434fe43..4c8a5f7 100644 --- a/crypto/rand/urandom.c +++ b/crypto/rand/urandom.c
@@ -96,8 +96,6 @@ urandom_fd = fd; } -void RAND_cleanup(void) {} - void RAND_set_urandom_fd(int fd) { fd = dup(fd); if (fd < 0) {
diff --git a/crypto/rand/windows.c b/crypto/rand/windows.c index 5a9a96b..de9f4d9 100644 --- a/crypto/rand/windows.c +++ b/crypto/rand/windows.c
@@ -35,9 +35,6 @@ #include "internal.h" -void RAND_cleanup(void) { -} - void CRYPTO_sysrand(uint8_t *out, size_t requested) { while (requested > 0) { ULONG output_bytes_this_pass = ULONG_MAX;