diff options
author | Simon Josefsson <simon@josefsson.org> | 2004-08-16 20:21:02 +0000 |
---|---|---|
committer | Simon Josefsson <simon@josefsson.org> | 2004-08-16 20:21:02 +0000 |
commit | 2a6b8d4f88e527cdae6fc2ed178589b623ee4659 (patch) | |
tree | a2e49b490db8f99d18b063d52019f0839ceb8c38 /crypto | |
parent | 8c54a466949d353539eb367243dc37a84f3ff4e6 (diff) | |
download | gnutls-2a6b8d4f88e527cdae6fc2ed178589b623ee4659.tar.gz |
Fix.
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/gc-nettle.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/crypto/gc-nettle.c b/crypto/gc-nettle.c index dc38c5f7ac..18669c1c6d 100644 --- a/crypto/gc-nettle.c +++ b/crypto/gc-nettle.c @@ -425,6 +425,7 @@ gc_hash_clone (gc_hash handle, gc_hash * outhandle) } memcpy (newhinf->context, oldhinf->context, newhinf->info->context_size); + memcpy (newhinf->digest, oldhinf->digest, MAX_DIGEST_SIZE); *outhandle = newhinf; @@ -493,6 +494,11 @@ gc_hash_close (gc_hash handle) { hinfo *hinf = (hinfo*) handle; + if (hinf->mode == GC_HMAC) + { + free (hinf->inner); + free (hinf->outer); + } free (hinf->context); free (hinf); } |