From dd021e6449595bce14891a2bf5715c5c390fcac8 Mon Sep 17 00:00:00 2001 From: Hamcha Date: Sun, 12 Oct 2014 01:05:06 +0200 Subject: [PATCH] Fallback only if EGD is selected --- libratbox/src/openssl.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libratbox/src/openssl.c b/libratbox/src/openssl.c index 00c4bf6..b249374 100644 --- a/libratbox/src/openssl.c +++ b/libratbox/src/openssl.c @@ -522,7 +522,9 @@ rb_init_prng(const char *path, prng_seed_t seed_type) { /* We may not have EGD (old OpenSSL / LibreSSL), fall back to default */ #ifndef HAVE_SSL_RAND_EGD - seed_type = RB_PRNG_DEFAULT; + if (seed_type == RB_PRNG_EGD) { + seed_type = RB_PRNG_DEFAULT; + } #endif if(seed_type == RB_PRNG_DEFAULT) {