diff options
| author | Jay Satiro <raysatiro@yahoo.com> | 2017-01-17 02:53:29 -0500 | 
|---|---|---|
| committer | Jay Satiro <raysatiro@yahoo.com> | 2017-01-17 02:53:59 -0500 | 
| commit | afd1564215970f75439ac4e83a7974efa8c739c6 (patch) | |
| tree | 6418fb91f7bf0ae788e7208bffbe847f5a3aa21b /lib | |
| parent | 25543b8392b2b9e18eb07e6140d351231e666ed1 (diff) | |
openssl: Fix random generation
- Fix logic error in Curl_ossl_random.
Broken a few days ago in 807698d.
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/vtls/openssl.c | 2 | 
1 files changed, 1 insertions, 1 deletions
| diff --git a/lib/vtls/openssl.c b/lib/vtls/openssl.c index 63fad71fc..48a4c0b02 100644 --- a/lib/vtls/openssl.c +++ b/lib/vtls/openssl.c @@ -3286,7 +3286,7 @@ CURLcode Curl_ossl_random(struct Curl_easy *data, unsigned char *entropy,    }    /* RAND_bytes() returns 1 on success, 0 otherwise.  */    rc = RAND_bytes(entropy, curlx_uztosi(length)); -  return rc?CURLE_FAILED_INIT:CURLE_OK; +  return (rc == 1 ? CURLE_OK : CURLE_FAILED_INIT);  }  void Curl_ossl_md5sum(unsigned char *tmp, /* input */ | 
