aboutsummaryrefslogtreecommitdiff
path: root/lib/vtls/vtls.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2017-09-06 09:32:02 +0200
committerDaniel Stenberg <daniel@haxx.se>2017-09-07 15:59:42 +0200
commit4bb80d532e73045b06d23228b3a501d9f7c93acf (patch)
tree3fa8ca88c634ce9f3afe18751218aa115ab0e649 /lib/vtls/vtls.c
parent6b585b1183ec9191eae411a4d7b47c565a061b53 (diff)
vtls: switch to CURL_SHA256_DIGEST_LENGTH define
... instead of the prefix-less version since WolfSSL 3.12 now uses an enum with that name that causes build failures for us. Fixes #1865 Closes #1867 Reported-by: Gisle Vanem
Diffstat (limited to 'lib/vtls/vtls.c')
-rw-r--r--lib/vtls/vtls.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/vtls/vtls.c b/lib/vtls/vtls.c
index f15760342..a1a301e7f 100644
--- a/lib/vtls/vtls.c
+++ b/lib/vtls/vtls.c
@@ -815,13 +815,14 @@ CURLcode Curl_pin_peer_pubkey(struct Curl_easy *data,
}
/* compute sha256sum of public key */
- sha256sumdigest = malloc(SHA256_DIGEST_LENGTH);
+ sha256sumdigest = malloc(CURL_SHA256_DIGEST_LENGTH);
if(!sha256sumdigest)
return CURLE_OUT_OF_MEMORY;
Curl_ssl->sha256sum(pubkey, pubkeylen,
- sha256sumdigest, SHA256_DIGEST_LENGTH);
+ sha256sumdigest, CURL_SHA256_DIGEST_LENGTH);
encode = Curl_base64_encode(data, (char *)sha256sumdigest,
- SHA256_DIGEST_LENGTH, &encoded, &encodedlen);
+ CURL_SHA256_DIGEST_LENGTH, &encoded,
+ &encodedlen);
Curl_safefree(sha256sumdigest);
if(encode)