X-Git-Url: http://wagner.pp.ru/gitweb/?a=blobdiff_plain;f=gost_omac.c;h=91e9a48b5794ac0c1eb075de3dea21f8aaaf2b09;hb=b629c446ff7246e526999bfdd2657e774faf306f;hp=0cbd45d2dd02a7913ba2bf382889da048e6a7b23;hpb=4c04300b7523a9e270a719dd66ac7136e899811d;p=openssl-gost%2Fengine.git diff --git a/gost_omac.c b/gost_omac.c index 0cbd45d..91e9a48 100644 --- a/gost_omac.c +++ b/gost_omac.c @@ -132,6 +132,7 @@ static int omac_key(OMAC_CTX * c, const EVP_CIPHER *cipher, { int ret = 0; + CMAC_CTX_free(c->cmac_ctx); c->cmac_ctx = CMAC_CTX_new(); if (c->cmac_ctx == NULL) { GOSTerr(GOST_F_OMAC_KEY, ERR_R_MALLOC_FAILURE);