[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnurl] 142/282: md4: Fixed compilation issues when using GNU TLS gcrypt
From: |
gnunet |
Subject: |
[gnurl] 142/282: md4: Fixed compilation issues when using GNU TLS gcrypt |
Date: |
Wed, 01 Apr 2020 14:30:07 +0200 |
This is an automated email from the git hooks/post-receive script.
ng0 pushed a commit to branch master
in repository gnurl.
commit 84762ff815d946ea104b600598b32c3bb558ad06
Author: Steve Holme <address@hidden>
AuthorDate: Thu Feb 20 18:55:55 2020 +0000
md4: Fixed compilation issues when using GNU TLS gcrypt
* Don't include 'struct' in the gcrypt MD4_CTX typedef
* The call to gcry_md_read() should use a dereferenced ctx
* The call to gcry_md_close() should use a dereferenced ctx
Additional minor whitespace issue in the USE_WIN32_CRYPTO code.
Closes #4959
---
lib/md4.c | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/lib/md4.c b/lib/md4.c
index d02e1764c..2cf674557 100644
--- a/lib/md4.c
+++ b/lib/md4.c
@@ -65,10 +65,11 @@ static void MD4_Final(unsigned char *result, MD4_CTX *ctx)
#include <gcrypt.h>
#include "curl_memory.h"
+
/* The last #include file should be: */
#include "memdebug.h"
-typedef struct gcry_md_hd_t MD4_CTX;
+typedef gcry_md_hd_t MD4_CTX;
static void MD4_Init(MD4_CTX *ctx)
{
@@ -82,8 +83,8 @@ static void MD4_Update(MD4_CTX *ctx, const void *data,
unsigned long size)
static void MD4_Final(unsigned char *result, MD4_CTX *ctx)
{
- memcpy(result, gcry_md_read(ctx, 0), MD4_DIGEST_LENGTH);
- gcry_md_close(ctx);
+ memcpy(result, gcry_md_read(*ctx, 0), MD4_DIGEST_LENGTH);
+ gcry_md_close(*ctx);
}
#elif defined(USE_OPENSSL) && !defined(OPENSSL_NO_MD4)
@@ -95,6 +96,7 @@ static void MD4_Final(unsigned char *result, MD4_CTX *ctx)
#include <CommonCrypto/CommonDigest.h>
#include "curl_memory.h"
+
/* The last #include file should be: */
#include "memdebug.h"
@@ -135,7 +137,8 @@ static void MD4_Final(unsigned char *result, MD4_CTX *ctx)
#include <wincrypt.h>
#include "curl_memory.h"
- /* The last #include file should be: */
+
+/* The last #include file should be: */
#include "memdebug.h"
typedef struct {
--
To stop receiving notification emails like this one, please contact
address@hidden.
- [gnurl] 109/282: CURLOPT_ALTSVC_CTRL.3: fix the DEFAULT wording, (continued)
- [gnurl] 109/282: CURLOPT_ALTSVC_CTRL.3: fix the DEFAULT wording, gnunet, 2020/04/01
- [gnurl] 117/282: azure: disable brotli on the macos debug-builds, gnunet, 2020/04/01
- [gnurl] 125/282: cookies: make saving atomic with a rename, gnunet, 2020/04/01
- [gnurl] 122/282: multi: if Curl_readwrite sets 'comeback' use expire, not loop, gnunet, 2020/04/01
- [gnurl] 119/282: TODO: Paged searches on LDAP server, gnunet, 2020/04/01
- [gnurl] 133/282: HTTP-COOKIES: mention that a trailing newline is required, gnunet, 2020/04/01
- [gnurl] 130/282: SOCKS: fix typo in printf formatting, gnunet, 2020/04/01
- [gnurl] 127/282: altsvc: make saving the cache an atomic operation, gnunet, 2020/04/01
- [gnurl] 129/282: CURLOPT_REDIR_PROTOCOLS.3: update the DEFAULT section, gnunet, 2020/04/01
- [gnurl] 135/282: win32: USE_WIN32_CRYPTO to enable Win32 based MD4, MD5 and SHA256 functions, gnunet, 2020/04/01
- [gnurl] 142/282: md4: Fixed compilation issues when using GNU TLS gcrypt,
gnunet <=
- [gnurl] 131/282: tool_util: Improve Windows version of tvnow(), gnunet, 2020/04/01
- [gnurl] 128/282: docs/GOVERNANCE: refreshed + added "donations" and "commercial support", gnunet, 2020/04/01
- [gnurl] 138/282: GnuTLS: Always send client cert, gnunet, 2020/04/01
- [gnurl] 134/282: connect: remove some spurious infof() calls, gnunet, 2020/04/01
- [gnurl] 136/282: cleanup: comment typos, gnunet, 2020/04/01
- [gnurl] 139/282: gtls: fix the copyright year, gnunet, 2020/04/01
- [gnurl] 132/282: nit: Copyright year out of date, gnunet, 2020/04/01
- [gnurl] 137/282: github action: add CIFuzz, gnunet, 2020/04/01
- [gnurl] 141/282: RELEASE-NOTES: synced, gnunet, 2020/04/01
- [gnurl] 143/282: tests: Added a unit test for SHA256 digest generation, gnunet, 2020/04/01