summaryrefslogtreecommitdiff
path: root/crypto/mdc2/mdc2_one.c
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/mdc2/mdc2_one.c')
-rw-r--r--crypto/mdc2/mdc2_one.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/crypto/mdc2/mdc2_one.c b/crypto/mdc2/mdc2_one.c
index cd569aa865..72647f67ed 100644
--- a/crypto/mdc2/mdc2_one.c
+++ b/crypto/mdc2/mdc2_one.c
@@ -66,7 +66,8 @@ unsigned char *MDC2(const unsigned char *d, size_t n, unsigned char *md)
static unsigned char m[MDC2_DIGEST_LENGTH];
if (md == NULL) md=m;
- MDC2_Init(&c);
+ if (!MDC2_Init(&c))
+ return NULL;
MDC2_Update(&c,d,n);
MDC2_Final(md,&c);
OPENSSL_cleanse(&c,sizeof(c)); /* security consideration */