summaryrefslogtreecommitdiffstats
path: root/Utilities/cmlibarchive/libarchive/archive_openssl_hmac_private.h
diff options
context:
space:
mode:
Diffstat (limited to 'Utilities/cmlibarchive/libarchive/archive_openssl_hmac_private.h')
-rw-r--r--Utilities/cmlibarchive/libarchive/archive_openssl_hmac_private.h6
1 files changed, 1 insertions, 5 deletions
diff --git a/Utilities/cmlibarchive/libarchive/archive_openssl_hmac_private.h b/Utilities/cmlibarchive/libarchive/archive_openssl_hmac_private.h
index d4ae0d1..2deeb5f 100644
--- a/Utilities/cmlibarchive/libarchive/archive_openssl_hmac_private.h
+++ b/Utilities/cmlibarchive/libarchive/archive_openssl_hmac_private.h
@@ -33,11 +33,7 @@
#include <string.h> /* memset */
static inline HMAC_CTX *HMAC_CTX_new(void)
{
- HMAC_CTX *ctx = (HMAC_CTX *)malloc(sizeof(HMAC_CTX));
- if (ctx != NULL) {
- memset(ctx, 0, sizeof(*ctx));
- HMAC_CTX_init(ctx);
- }
+ HMAC_CTX *ctx = (HMAC_CTX *)calloc(1, sizeof(HMAC_CTX));
return ctx;
}