mirror of
https://github.com/moparisthebest/curl
synced 2024-11-15 22:15:13 -05:00
wolfssl: use the wc-prefixed symbol alternatives
The symbols without wc_ prefix are not always provided. Ref: https://github.com/wolfSSL/wolfssl/issues/2744 Closes #4827
This commit is contained in:
parent
6357a19ff2
commit
59c1caf7f6
@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2019, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2020, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@ -923,7 +923,7 @@ static CURLcode Curl_wolfssl_connect(struct connectdata *conn, int sockindex)
|
|||||||
static CURLcode Curl_wolfssl_random(struct Curl_easy *data,
|
static CURLcode Curl_wolfssl_random(struct Curl_easy *data,
|
||||||
unsigned char *entropy, size_t length)
|
unsigned char *entropy, size_t length)
|
||||||
{
|
{
|
||||||
RNG rng;
|
WC_RNG rng;
|
||||||
(void)data;
|
(void)data;
|
||||||
if(wc_InitRng(&rng))
|
if(wc_InitRng(&rng))
|
||||||
return CURLE_FAILED_INIT;
|
return CURLE_FAILED_INIT;
|
||||||
@ -937,11 +937,11 @@ static CURLcode Curl_wolfssl_random(struct Curl_easy *data,
|
|||||||
}
|
}
|
||||||
|
|
||||||
static CURLcode Curl_wolfssl_sha256sum(const unsigned char *tmp, /* input */
|
static CURLcode Curl_wolfssl_sha256sum(const unsigned char *tmp, /* input */
|
||||||
size_t tmplen,
|
size_t tmplen,
|
||||||
unsigned char *sha256sum /* output */,
|
unsigned char *sha256sum /* output */,
|
||||||
size_t unused)
|
size_t unused)
|
||||||
{
|
{
|
||||||
Sha256 SHA256pw;
|
wc_Sha256 SHA256pw;
|
||||||
(void)unused;
|
(void)unused;
|
||||||
wc_InitSha256(&SHA256pw);
|
wc_InitSha256(&SHA256pw);
|
||||||
wc_Sha256Update(&SHA256pw, tmp, (word32)tmplen);
|
wc_Sha256Update(&SHA256pw, tmp, (word32)tmplen);
|
||||||
|
Loading…
Reference in New Issue
Block a user