summaryrefslogtreecommitdiffstats
path: root/cryptodev_cipher.c
diff options
context:
space:
mode:
Diffstat (limited to 'cryptodev_cipher.c')
-rw-r--r--cryptodev_cipher.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/cryptodev_cipher.c b/cryptodev_cipher.c
index 05e6db3..fa5aab2 100644
--- a/cryptodev_cipher.c
+++ b/cryptodev_cipher.c
@@ -262,12 +262,14 @@ int ret;
if (unlikely(ret)) {
dprintk(0,KERN_ERR,
"error in crypto_hash_init()\n");
- goto error;
+ goto error_request;
}
hdata->init = 1;
return 0;
+error_request:
+ ahash_request_free(hdata->async.request);
error:
kfree(hdata->async.result);
crypto_free_ahash(hdata->async.s);