From 942c952db6d81c4ea52ea40daf8470a0d3e3e420 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Fri, 11 Nov 2016 13:54:16 +0100 Subject: openssl: avoid unnecessary seeding if already done 1.1.0+ does more of this by itself so we can avoid extra processing this way. --- lib/vtls/openssl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib') diff --git a/lib/vtls/openssl.c b/lib/vtls/openssl.c index 9cf36b358..fa128fa46 100644 --- a/lib/vtls/openssl.c +++ b/lib/vtls/openssl.c @@ -188,8 +188,8 @@ static int ossl_seed(struct Curl_easy *data) char *buf = data->state.buffer; /* point to the big buffer */ int nread=0; - /* Q: should we add support for a random file name as a libcurl option? - A: Yes, it is here */ + if(rand_enough()) + return 1; #ifndef RANDOM_FILE /* if RANDOM_FILE isn't defined, we only perform this if an option tells -- cgit v1.2.3