From bd8eb3f218120fc90bed1d647aba5f4613f55320 Mon Sep 17 00:00:00 2001 From: "Evgeny Grin (Karlson2k)" Date: Wed, 31 Jan 2024 23:11:22 +0100 Subject: [PATCH] Unified handling of external hash function for MD5 and SHA-256 --- src/microhttpd/md5_ext.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/microhttpd/md5_ext.h b/src/microhttpd/md5_ext.h index 435991c1..9d7c40c7 100644 --- a/src/microhttpd/md5_ext.h +++ b/src/microhttpd/md5_ext.h @@ -29,7 +29,6 @@ #ifdef HAVE_STDDEF_H #include /* for size_t */ #endif /* HAVE_STDDEF_H */ -#include /** * Size of MD5 resulting digest in bytes @@ -37,6 +36,8 @@ */ #define MD5_DIGEST_SIZE (16) +/* Actual declaration is in GnuTLS lib header */ +struct hash_hd_st; /** * Indicates that struct Md5CtxExt has 'ext_error' @@ -48,7 +49,7 @@ */ struct Md5CtxExt { - gnutls_hash_hd_t handle; /**< Hash calculation handle */ + struct hash_hd_st *handle; /**< Hash calculation handle */ int ext_error; /**< Non-zero if external error occurs during init or hashing */ };