projects
/
openssl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Use safer sizeof variant in malloc
[openssl.git]
/
crypto
/
cmac
/
cmac.c
diff --git
a/crypto/cmac/cmac.c
b/crypto/cmac/cmac.c
index 5e8fdc399bb7ed59d21ff9879df3036da19725eb..e7db3206f5a28e619661402400a1c055c19f7bd7 100644
(file)
--- a/
crypto/cmac/cmac.c
+++ b/
crypto/cmac/cmac.c
@@
-90,7
+90,8
@@
static void make_kn(unsigned char *k1, const unsigned char *l, int bl)
CMAC_CTX *CMAC_CTX_new(void)
{
CMAC_CTX *ctx;
- ctx = OPENSSL_malloc(sizeof(CMAC_CTX));
+
+ ctx = OPENSSL_malloc(sizeof(*ctx));
if (!ctx)
return NULL;
EVP_CIPHER_CTX_init(&ctx->cctx);